you can simply use a recursive function like this: void intTobinary(int num){ if(num>0){ intTobinary(num/2);...
I did'nt read your whole program when I saw that you did not put a scanf just after you asked for the letter. Do that then see what you get
Separate names with a comma.