My code:
char function [100];
switch (function [i]) {
case '+' : {
} break;
case '*': {
}break;
case '\'' :{
}break;
default: {
printf ("argument %c not recognized \n", function [i]);
return 1;
}
} return 0;
I'm executing program with:
./a.out "AB+A'*"
but everything what I see is that apostrophe is not recognized. How I should write this switch case? Of course I can't give
./a.out "AB+A\'*"
- \ not recognized
and
./a.out AB+A\'*
- ' not recognized