title: Python: how to make python calculate a sum to make sure an input is correct?
body: <p>I want to make python ask 10 questions and a user to have to input their answers which works. However I also want python to say whether this is correct or not by using the code below but this does not work and only moves onto the next question. Could anybody tell me why? Or what I need to change? Also how do I make this ask 10 question specifically using the variables I have and a while loop? </p>
  
  <pre><code>import time
  import random
  question = 0
  score = 0
  name = input("What is your full name?")
  print ("Hello " + name, "welcome to The Arithmetic Quiz")
  time.sleep(2)
  operand1 = list(range(2, 12))
  operators = ["+"]
  operand2 = list(range(2, 12))
  
  while question &lt; 10:
      user_answer=int(input(str(random.choice(operand1)) + random.choice(operators) + str(random.choice(operand2))))
      if operators=='+':
          expected_answer==operand1 + operand2
          if user_answer==expected_answer:
              print('This is correct!')
              score = score + 1
              question = question + 1
              time.sleep(2)
          else:
              print('This is incorrect!')
              question = question + 1
              time.sleep(2)
  </code></pre>