Hi folks.
I want to convert a String input to an Integer.
So far I have:
print 'Enter the numbers.'
read = sys.stdin.readline()
array = read.split()
firstNumber = int(array[0])
secondNumber = int(array[1])
thirdNumber = int(array[2])
...
Problem with this is that I think it's rather inefficient, as you must convert each cell one by one...
Is there a more efficient alternative solution to this conversion process???
Cheers,
ThompsonSensibl

1 year 43 weeks ago
Use following to create array of integers:
Post Comment