import getpass, sys

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

questions = 3
correct = 0

print('Hello, ' + getpass.getuser() + " running " + sys.executable)
print("You will be asked " + str(questions) + " questions.")

rsp = question_with_response("What is the best reason for choosing a stemplot rather than a histogram to display the distribution of a quantitative variable?")
if rsp == "Stemplots make it easier to determine the shape of a distribution":
    print(rsp + " is correct!")
    correct += 1
else:
    print(rsp + " is incorrect!")

rsp = question_with_response("The scores on a statistics test had a mean of 25 and a standard deviation of 3. If a score of 28 was added to the distribution of scores, what would happen to the mean and standard deviation?")
if rsp == "The mean will increase, and standard deviation will decrease":
    print(rsp + " is correct!")
    correct += 1
else:
    print(rsp + " is incorrect!")

rsp = question_with_response("There are many houses ranging from $200,000 to $500,000 in price. The few houses on the water, however, are priced up to $15 million. The distribution of house prices will be...?")
if rsp == "Skewed to the right":
    print(rsp + " is correct!")
    correct += 1
else:
    print(rsp + " is incorrect!")

print(getpass.getuser() + " you scored " + str(correct) +"/" + str(questions))
Hello, keira running /home/keira/anaconda3/bin/python
You will be asked 3 questions.
Question: What is the best reason for choosing a stemplot rather than a histogram to display the distribution of a quantitative variable?
Stemplots make it easier to determine the shape of a distribution is correct!
Question: The scores on a statistics test had a mean of 25 and a standard deviation of 3. If a score of 28 was added to the distribution of scores, what would happen to the mean and standard deviation?
The mean will increase, and standard deviation will decrease is correct!
Question: There are many houses ranging from $200,000 to $500,000 in price. The few houses on the water, however, are priced up to $15 million. The distribution of house prices will be...?
Skewed to the right is correct!
keira you scored 3/3