啊哈磊_编程从这里起步
标题:
显示“P”: 未声明的标识符,是头文件找不到吗?
[打印本页]
作者:
命运之轮
时间:
2020-11-18 15:11
标题:
显示“P”: 未声明的标识符,是头文件找不到吗?
#include <iostream>
#include <cstdio>
#include <cctype>
using namespace std;
int main()
{
char* p;
char str[80]="This is a Test";
cout<<"Original string:"<<str<<'';
p=str;
while(*p){
if(isupper(*p))
*p=tolower(*p);
else if(islower(*p))
*p=toupper(*p);
P++;
}
cout<<"Inverted-case string:"<<str<<endl;
return 0;
}
复制代码
欢迎光临 啊哈磊_编程从这里起步 (https://bbs.codeaha.com/)
Powered by Discuz! X3.2