Hi guys ,
I have the following code :
x=int(input())
If I get a string from the user string ,list or a double , then I'd an exception .
Is there a way to get any input from any type , and store it within "x" , even though
I write "x=int(input())" ?
meaning is , if I get the string "onetwothree" into the variable 'x' , then
first I need to define 'x' as "onetwothree" , and then execute the
"x=int(input())
I've tried with 'type' :
def translate(someType):
return (type(someType))
but it didn't work out . I'd appreciate any ideas on the matter
Regards,Ron