Hey!, so I have this little problem that I have to fix really quick, its really simple and maybe someone can help me.
[Cpp]scanf("%d", &programs);
if (programs >= 6) {
printf(" there's only 5 programs in the options ");
}
else {
switch (programs){
case 1:
printf("Type the string\n");
getch();
gets_s(c);
[/Cpp]
Ok, the thing is the gets_s(c); doesn't ask me for the string (while running the program). So I just type the "1" for the first case and I get "Type the string" "The string has 0 numbers" "The String has 0 letters".
I need to actually type the string but it doesn't work, I know is really basic but I can't get it to work, and I'm pretty newbie at this.
the getch(); shouldn't be there but I just added it so it stops before asking for the string but it doesn't work either.
[Cpp]scanf("%d", &programs);
if (programs >= 6) {
printf(" there's only 5 programs in the options ");
}
else {
switch (programs){
case 1:
printf("Type the string\n");
getch();
gets_s(c);
[/Cpp]
Ok, the thing is the gets_s(c); doesn't ask me for the string (while running the program). So I just type the "1" for the first case and I get "Type the string" "The string has 0 numbers" "The String has 0 letters".
I need to actually type the string but it doesn't work, I know is really basic but I can't get it to work, and I'm pretty newbie at this.
the getch(); shouldn't be there but I just added it so it stops before asking for the string but it doesn't work either.