Welcome to the quiz, What Type of Bread are You? Answer the questions below.

white_bread = 0
flat_bread = 0
sourdough_bread = 0

#defines variables for types of breads and point values


def question_and_3_answers(prompt, ans1, ans2, ans3):
    answer_correct = 0
    while answer_correct == 0:
        print("Question: " + prompt)
        rsp = input()
        if rsp == ans1:
            global white_bread
            white_bread += 1
            answer_correct = 1
        elif rsp == ans2:
            global sourdough_bread
            sourdough_bread += 1
            answer_correct = 1
        elif rsp == ans3:
            global flat_bread
            flat_bread += 1
            answer_correct = 1
        else:
            print(rsp + " is not an answer please try again")
    
#this is defining my function. I have a prompt and three correct answers- This way I don't have to type this code five times.
#if the user types a non-answer, it will loop until they choose a defined answer. Certain answers will add a point to the bread total

question_and_3_answers("What type of friend are you? The mom, rebellious, or quiet friend? Answer with one word.", "mom", "rebellious", "quiet")
question_and_3_answers("What kind of car would you drive? A minivan, Tesla, or Prius? Make sure to type a capital letter if applicable.", "minivan", "Tesla", "Prius")
question_and_3_answers("What activity would you do in your freetime? Would you run errands, party, or read?", "run errands", "party", "read")
question_and_3_answers("What kind of phone do you use? A flip phone, an iphone, or an android?", "flip phone", "iphone", "android")
question_and_3_answers("What pet would you like to own? A cat, a dog, or a fish?","cat","dog","fish")

print("Here are your results:   " + str(white_bread) + "/5 whitebread   " + str(sourdough_bread) + "/5 sourdough   " + str(flat_bread) + "/5 flatbread")
print("Thanks for playing! Now you can live your life knowing your bread genetics! :)")

#this gives the user results about how much of each bread they are
Question: What type of friend are you? The mom, rebellious, or quiet friend? Answer with one word.
Question: What kind of car would you drive? A minivan, Tesla, or Prius? Make sure to type a capital letter if applicable.
mom is not an answer please try again
Question: What kind of car would you drive? A minivan, Tesla, or Prius? Make sure to type a capital letter if applicable.
Question: What activity would you do in your freetime? Would you run errands, party, or read?
Question: What kind of phone do you use? A flip phone, an iphone, or an android?
Question: What pet would you like to own? A cat, a dog, or a fish?
Here are your results:   1/5 whitebread   2/5 sourdough   2/5 flatbread
Thanks for playing! Now you can live your life knowing your bread genetics! :)