Posted 18 July 2012 - 02:37 AM
Hey guys,
I need help with some code.
I need to be able to take user input (for a number) from io.read() and change it from a string into a variable or whatever can be used in math.
e.g
I need help with some code.
I need to be able to take user input (for a number) from io.read() and change it from a string into a variable or whatever can be used in math.
e.g
print("please enter a number: ")
number = io.read()
type(number)
when the type(number) executes, it says that the number is a string, how can i change it into a number?