answersLogoWhite

0

static void tobin_core (int n)

{

if (n>1) tobin_core (n/2);

putchar ('0'+n%2);

}

void tobin (int n)

{

if (n<0) { putchar ('-'); n= -n; }

tobin_core (n);

}

User Avatar

Wiki User

14y ago

What else can I help you with?

Related Questions

How do you write a c program to convert binary to decimal by using while statement?

write a c++ program to convert binary number to decimal number by using while statement


How do you convert a binary number into a decimal in C?

sprintf (to, "%d", value)


Write a c program to convert binary number to decimal number?

How is this a question? Sounds like you should do more of your homework offline.


C plus plus program that convert decimal to binary using the concept of stack?

#include&lt;stdio.h&gt; #include&lt;stdlib.h&gt; main() { int number,binary[10000],b=0; printf("Enter decimal number "); scanf("%d",&amp;number); printf("\nBinary: "); for(;number;number/=2,b++) binary[b]=number%2; for(b--;b&gt;-1;b--) printf("%d ",binary[b]); }


What does B C D stand for in math?

Binary coded decimal. Each decimal digit is represented by its binary equivalent.


C program to convert decimal number into binary number?

#include&lt;stdio.h&gt; main() { int d,a; printf("enter the number"); scanf("%d",&amp;a); do { d=a%2; } while(a=0); printf("binary=%d",&amp;d); }


How do you convert A B C in binary code?

A = 1010 b = 1011 c = 1100


Decimal to binary conversion in c language?

sscanf, atoi, strtol, ...


Convert decimal number 12 into hexa decimal number?

It is C


C program to receive floating point and convert it into binary?

scanf


How do you convert text into binary in vb or c sharp code?

C# EXAMPLEString text="My sample data";System.Text.ASCIIEncoding encode=new System.Text.ASCIIEncoding();//convert to binary and store in a byte[]byte[] binaryArray=encode.GetBytes(text);


Code for binary trees written in C using graphics?

cg code for binary tree