-1
I need to make a program that compares several strings, I already tried to make one switch
but it didn’t work because it only accepts a comparison character. I need each dot to represent a letter, example:
a .
b ..
c ...
d ... .
That’s what I could do:
#include <stdio.h>
#include <stdlib.h>
int main () {
char letra;
printf("Digite os pontos:");
scanf("%s",&letra);
switch (letra){
case '..':
printf("a\n");
break;
case '..':
printf("b\n");
break;
}
system("pause");
return 0;
}