Binary to Base 10

0 J show · February 17, 2015
How do you guys suppose to go about this?

Post a Reply


Oldest  Newest  Rating
+1 Lazar Bulic · February 17, 2015
0 J show · February 17, 2015
I wanted to write code on it.. I know how to do it by hand i'm just trying ti figure out how to write the code for it.
0 c student · February 17, 2015
if you can do it by hand in a systematic way, you can formulate an algorithm for it.  get your pseudo code correct and simply turn it into code.
0 J show · February 17, 2015
Alright i'll try! haha

I wrote the base 10 to binary code :

#include <stdio.h>
int main(void)
       int value, binary;
       printf("Enter base ten number you want converted to binary:");
       scanf("%d", &value);
              binary = value%2;
              value = value/2;
              printf("%d", binary);
return 0;

Now i just have to figure out how to display it in reverse order. ha
0 Lazar Bulic · February 17, 2015
Make an array of ints and display it  in reverse order.
  • 1



One of the most popular languages of all time.

Bucky Roberts Administrator