Evaluates user input.
input ([prompt])
- prompt
- Optional. The prompt text.
#TODO
#TODO
Input is equivalent to eval(raw_input(prompt)).
This function does not catch user errors. If the input is not syntactically valid, a SyntaxError will be raised. Other exceptions may be raised if there is an error during evaluation.
If the readline module was loaded, then input() will use it to provide elaborate line editing and history features. Consider using the raw_input() function for general input from users.
>>> input()
2+2
4
>>> input('Enter a valid python expression...\n')
Enter a valid python expression...
2*2
4#TODO