import getpass, sys

questions = 3
correct = 0

def question_with_response(prompt):
    print("Question: " + prompt)
    msg = input()
    return msg

def question_and_answer(prompt):
    print("Question: " + prompt)
    msg = input()
    print("Answer: " + msg)

question_and_answer("what is your favorite class in school?")
question_and_answer("Do you like this class?")
question_and_answer("How has your day been?")

print('Hello, ' + getpass.getuser() + " running " + sys.executable)
print("You will be asked " + str(questions) + " questions.")
question_and_answer("Are you ready for some questions?")


rsp = question_with_response("Who is the creator of Apple?")
if rsp == "Steve Jobs":
    print(rsp + " is correct!")
    correct += 1
else:
    print(rsp + " is incorrect!")

rsp = question_with_response("what is 10+40?")
if rsp == "50":
    print(rsp + " is correct!")
    correct += 1
else:
    print(rsp + " is incorrect!")

rsp = question_with_response("Is Toby leeder the hotest of them all?")
if rsp == "yes":
    print(rsp + " is correct!")
    correct += 1
else:
    print(rsp + " is incorrect!")

print(getpass.getuser() + " you scored " + str(correct) +"/" + str(questions))
Question: what is your favorite class in school?
Answer: Math
Question: Do you like this class?
Answer: yes
Question: How has your day been?
Answer: good
Hello, Caleb running c:\Users\Caleb\AppData\Local\Programs\Python\Python310\python.exe
You will be asked 3 questions.
Question: Are you ready for some questions?
Answer: good
Question: Who is the creator of Apple?
Your mom is incorrect!
Question: what is 10+40?
your mom is incorrect!
Question: Is Toby leeder the hotest of them all?
69 is incorrect!
Caleb you scored 0/3