Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
124733 | 王金檐 | 字符的前导值和后继值 | C++ | Compile Error | 0 MS | 0 KB | 291 | 2025-07-12 11:54:48 |
#include <iostream> using namespace std; int main(){ int s; char c; c=getchar(); s=int (c); if(s-1>=32&&s-1<=){ cout<<s-1<<endl; }else{ cout<<"Input Error!"<<endl; } if(s-1>=32&&s-1<=){ cout<<s+1<<endl; }else{ cout<<"Input Error!"<<endl; } return 0; }
Main.cc: In function 'int main()': Main.cc:8:19: error: expected primary-expression before ')' token if(s-1>=32&&s-1<=){ ^ Main.cc:13:19: error: expected primary-expression before ')' token if(s-1>=32&&s-1<=){ ^