Reading integers until end of input
HI,
I am writing a program that turns decimal numbers to their binary form. The transforming from decimal to binary is easy but I have a problem with the input.
I should be able to receive any length of input but I am not allowed to keep it in an array.
The display of output should take place only after the user finishes inserting the numbers.
For example:
Input: 3 4 9
output:
3 11
4 100
9 1001
Also, I should get receive the numbers as integers and not as string.
So, have any idea?
thanks,
nivo