以下程序的输出结果是
#include<ctype.h>
space(char *str)
{ int i,t; char ts[81];
for(i=0,t=0;str[i]!=’\0’;i+=2)
if (!isspace(*str+i)&&(*( str+i)!=’a’))
ts[t++]=toupper(str[i]);
ts[t]=’\0’;
strcpy(str,ts);
}
main()
{ char s[81]={“a b c d e f g”};
space(s);
puts(s);
}
A abcdefg B bcde C ABCDE D BCDEFG
请问 if (!isspace(*str+i)&&(*( str+i)!=’a’)) 这句话中isspace没定义表示的是什么? 有什么作用?
还有就是 ts[t++]=toupper(str[i]); 语句中toupper 也没用定义.也不知道表示什么作用