当前位置: 技术问答>linux和unix
请教:各位大哥,我下面这段程序有几个错误,请帮帮我,谢谢!
来源: 互联网 发布时间:2015-12-02
本文导语: #include #include char *upcase(char *inputstring); int main() { char *str1,*str2; str1=upcase("hello"); str2=capitao("goodbye"); printf("st1=%s,str2=%s n",str1,str2); return 0; } char *upcase (char *oldstring) { int counter; char newstring[100]; ...
#include
#include
char *upcase(char *inputstring);
int main()
{
char *str1,*str2;
str1=upcase("hello");
str2=capitao("goodbye");
printf("st1=%s,str2=%s n",str1,str2);
return 0;
}
char *upcase (char *oldstring)
{
int counter;
char newstring[100];
strcpy(newstring,oldstring);
for(counter=0;counter=97&&newstring[counter]
#include
char *upcase(char *inputstring);
int main()
{
char *str1,*str2;
str1=upcase("hello");
str2=capitao("goodbye");
printf("st1=%s,str2=%s n",str1,str2);
return 0;
}
char *upcase (char *oldstring)
{
int counter;
char newstring[100];
strcpy(newstring,oldstring);
for(counter=0;counter=97&&newstring[counter]