This program was originally written in Java, but I have converted everything except: 'printf(Integer.toBinaryString(iNum));'
What would I change that to? This is an integer to binary program. I apologize, I am a newb at this.
Code:#include <stdio.h> #include <c:\learning.h> int main() { int iNum; printf("Please enter a positive integer, or press 0 to quit\n\n"); scanf("%d",&iNum); while ( iNum != 0) { printf(Integer.toBinaryString(iNum)); printf("Enter another integer or 0 to quit\n\n"); scanf("%d",&iNum); } }