07/09/05 00:50:15
>>225
#include <stdio.h>
#include <ctype.h>
char toul(char ch)
{
if(isupper(ch))
return tolower(ch);
else if(islower(ch))
return toupper(ch);
else
return ch;
}
int main(void)
{
printf("'%c' → '%c'\n", 'a', toul('a'));
printf("'%c' → '%c'\n", 'B', toul('B'));
printf("'%c' → '%c'\n", ' ', toul(' '));
printf("'%c' → '%c'\n", '2', toul('2'));
return 0;
}