What does the "eval()" function do in Python?
<p>Please consider a code:</p>

<pre><code>import random
name = input("Welcome to this Arithmetic quiz,please enter your name:")

number1 = random.randint(20,50)
number2 = random.randint(1,20)
oper = random.choice('+-*')

result = eval(str(number1)+oper+str(number2))
answer = (int(input('What is:'+str(number1)+oper+str(number2)+'=')) == result)

if answer == True:
    print('Correct!')
else:
    print('Incorrect!')
</code></pre>

<p>What is the difference between the <code>answer</code> and <code>result</code> variables and what is the point of <code>eval</code>, what's it's purpose ?</p>