Hi guys, I'm new to this forms and this is my first post.
I'm currently working on my assignment which consists of menu driven program. For one of the sections I'm required to create a ASCII to binary generator.Anyway what i would like to know is why in this section of my code it doesn't let me enter char.
Code:
void ascii_binary(void)
{
char ch[2] ={0};
printf("Enter character: ");
gets(ch);
printf("You chave entered %s\n",ch);
scanf("%s",ch);
return;
}
(ps the code is not complete)
If i run the code in a separate file and compile it, it works.
Any help will be appreciated.
Thanks
SS