Answer:
* The code is in Python
def joinStrings():
  join = ""
  while True:
    str = input("Enter a word or Q to stop: ")
    if str == "Q":
      break
    else:
      join = join + " " + str
  return join
print(joinStrings())
Explanation:
Create a function called joinStrings
Initialize join variable to hold the strings that will be combined
Create a while loop that stops when user enters "Q". Otherwise, ask the user for a new string and join it to the join variable with a space
When the loop is done, return the join
Call the function and print the result