| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 75715 | 彭诗媛 | 03字符转ASCLL码 | C++ | Compile Error | 0 MS | 0 KB | 384 | 2024-05-28 19:23:44 |
#in#include<iostream> using namespace std; int main(){ char c; //定义一个字符类型的变量 cin>>c; //输入字符 cout<< int(c);//输出 return 0; } clude<iostream> using namespace std; int main(){ char a='A'; //定义一个字符类型的变量 cin>>a; //输入字符 a = 97 cout<<a;//输出 return 0; }
Main.cc:1:2: error: invalid preprocessing directive #in
#in#include
^
Main.cc: In function 'int main()':
Main.cc:5:5: error: 'cin' was not declared in this scope
cin>>c; //输入字符
^
Main.cc:6:5: error: 'cout' was not declared in this scope
cout<< int(c);//输出
^
Main.cc: At global scope:
Main.cc:10:4: error: 'clude' does not name a type
clude
^
Main.cc: In function 'int main()':
Main.cc:12:5: error: redefinition of 'int main()'
int main(){
^
Main.cc:3:5: note: 'int main()' previously defined here
int main(){
^
Main.cc:14:5: error: 'cin' was not declared in this scope
cin>>a; //输入字符
^
Main.cc:16:5: error: expected ';' before 'cout'
cout<