How would I be able to convert for example, turn 45 to turn(45)? Or in general reverse AnyValue to reverse(AnyValue) in python?
The user input could be:
reverse 45
And then the output could be:
reverse(45)
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You could use a regular expression to add the parenthesis around your numbers: