Sign in with
Sign up | Sign in
Your question

Help

Last response: in Windows 7
Share
November 25, 2012 4:43:07 PM

Hello,
I Need the c program that:
takes any binary number ( decimal number that only contains ones and zero e.g. 1011 represents 11 ) and prints its decimal value to the screen and vice versa ( decimal to binary).
Your program should display the following menu to the screen:

Please enter your choice (1-3):
1- From binary to decimal
2- From decimal to binary
3- Exit program

Your program should continue running until item 3 is selected by the user from the menu.
Each time a user selects item number 1, your program should ask the user to enter a binary number and then should call a function called bintodec that takes that binary number as a parameter and returns its decimal equivalent value to be printed by the main program. The same should be done for item 2, but using a function called dectobin.

More about : question

a b $ Windows 7
November 25, 2012 4:50:07 PM

Is there any reason you cannot use the built-in calculator?
m
0
l
a b $ Windows 7
November 25, 2012 4:57:38 PM

This kinds looks like he is having someone do his homework for him.
m
0
l
!