F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

View Compilation Error

0_0_26518299_25619.cpp:4:236: error: stray '#' in program
          using namespace std; int main() { char line[105]; while(gets(line)) { int len = strlen(line); if(line[0]!=' ') { line[0] = line[0]-32; } for(int i=1;i<len;i++) { if(line[i]==' ') { line[i+1]-=32; } } puts(line); } return 0; } #include <iostream>
                                                                                                                                                                                                                                            ^
0_0_26518299_25619.cpp:8:9: error: stray '\345' in program
         getchar()吃掉一个空字符,否则后面用gets()的时候就会产生错位的现象 for(int k=0;k<n;k++) { memset(yuannum,0,sizeof(yuannum)); gets(line); for(int i=0;i<strlen(line);i++) { for(int j=0;j<5;j++) { if(line[i]==yuan[j]) { yuannum[j]++; } } } for(int i=0;i<5;i++) { cout<<yuan[i]<<":"<<yuannum[i]<<endl; } if(k!=n-1)cout<<endl; } } return 0; }
         ^
0_0_26518299_25619.cpp:8:9: error: stray '\220' in program
0_0_26518299_25619.cpp:8:9: error: stray '\203' in program
0_0_26518299_25619.cpp:8:9: error: stray '\346' in program
0_0_26518299_25619.cpp:8:9: error: stray '\216' in program
0_0_26518299_25619.cpp:8:9: error: stray '\211' in program
0_0_26518299_25619.cpp:8:9: error: stray '\344' in program
0_0_26518299_25619.cpp:8:9: error: stray '\270' in program
0_0_26518299_25619.cpp:8:9: error: stray '\200' in program
0_0_26518299_25619.cpp:8:9: error: stray '\344' in program
0_0_26518299_25619.cpp:8:9: error: stray '\270' in program
0_0_26518299_25619.cpp:8:9: error: stray '\252' in program
0_0_26518299_25619.cpp:8:9: error: stray '\347' in program
0_0_26518299_25619.cpp:8:9: error: stray '\251' in program
0_0_26518299_25619.cpp:8:9: error: stray '\272' in program
0_0_26518299_25619.cpp:8:9: error: stray '\345' in program
0_0_26518299_25619.cpp:8:9: error: stray '\255' in program
0_0_26518299_25619.cpp:8:9: error: stray '\227' in program
0_0_26518299_25619.cpp:8:9: error: stray '\347' in program
0_0_26518299_25619.cpp:8:9: error: stray '\254' in program
0_0_26518299_25619.cpp:8:9: error: stray '\246' in program
0_0_26518299_25619.cpp:8:9: error: stray '\357' in program
0_0_26518299_25619.cpp:8:9: error: stray '\274' in program
0_0_26518299_25619.cpp:8:9: error: stray '\214' in program
0_0_26518299_25619.cpp:8:9: error: stray '\345' in program
0_0_26518299_25619.cpp:8:9: error: stray '\220' in program
0_0_26518299_25619.cpp:8:9: error: stray '\246' in program
0_0_26518299_25619.cpp:8:9: error: stray '\345' in program
0_0_26518299_25619.cpp:8:9: error: stray '\210' in program
0_0_26518299_25619.cpp:8:9: error: stray '\231' in program
0_0_26518299_25619.cpp:8:9: error: stray '\345' in program
0_0_26518299_25619.cpp:8:9: error: stray '\220' in program
0_0_26518299_25619.cpp:8:9: error: stray '\216' in program
0_0_26518299_25619.cpp:8:9: error: stray '\351' in program
0_0_26518299_25619.cpp:8:9: error: stray '\235' in program
0_0_26518299_25619.cpp:8:9: error: stray '\242' in program
0_0_26518299_25619.cpp:8:9: error: stray '\347' in program
0_0_26518299_25619.cpp:8:9: error: stray '\224' in program
0_0_26518299_25619.cpp:8:9: error: stray '\250' in program
0_0_26518299_25619.cpp:8:9: error: stray '\347' in program
0_0_26518299_25619.cpp:8:9: error: stray '\232' in program
0_0_26518299_25619.cpp:8:9: error: stray '\204' in program
0_0_26518299_25619.cpp:8:9: error: stray '\346' in program
0_0_26518299_25619.cpp:8:9: error: stray '\227' in program
0_0_26518299_25619.cpp:8:9: error: stray '\266' in program
0_0_26518299_25619.cpp:8:9: error: stray '\345' in program
0_0_26518299_25619.cpp:8:9: error: stray '\200' in program
0_0_26518299_25619.cpp:8:9: error: stray '\231' in program
0_0_26518299_25619.cpp:8:9: error: stray '\345' in program
0_0_26518299_25619.cpp:8:9: error: stray '\260' in program
0_0_26518299_25619.cpp:8:9: error: stray '\261' in program
0_0_26518299_25619.cpp:8:9: error: stray '\344' in program
0_0_26518299_25619.cpp:8:9: error: stray '\274' in program
0_0_26518299_25619.cpp:8:9: error: stray '\232' in program
0_0_26518299_25619.cpp:8:9: error: stray '\344' in program
0_0_26518299_25619.cpp:8:9: error: stray '\272' in program
0_0_26518299_25619.cpp:8:9: error: stray '\247' in program
0_0_26518299_25619.cpp:8:9: error: stray '\347' in program
0_0_26518299_25619.cpp:8:9: error: stray '\224' in program
0_0_26518299_25619.cpp:8:9: error: stray '\237' in program
0_0_26518299_25619.cpp:8:9: error: stray '\351' in program
0_0_26518299_25619.cpp:8:9: error: stray '\224' in program
0_0_26518299_25619.cpp:8:9: error: stray '\231' in program
0_0_26518299_25619.cpp:8:9: error: stray '\344' in program
0_0_26518299_25619.cpp:8:9: error: stray '\275' in program
0_0_26518299_25619.cpp:8:9: error: stray '\215' in program
0_0_26518299_25619.cpp:8:9: error: stray '\347' in program
0_0_26518299_25619.cpp:8:9: error: stray '\232' in program
0_0_26518299_25619.cpp:8:9: error: stray '\204' in program
0_0_26518299_25619.cpp:8:9: error: stray '\347' in program
0_0_26518299_25619.cpp:8:9: error: stray '\216' in program
0_0_26518299_25619.cpp:8:9: error: stray '\260' in program
0_0_26518299_25619.cpp:8:9: error: stray '\350' in program
0_0_26518299_25619.cpp:8:9: error: stray '\261' in program
0_0_26518299_25619.cpp:8:9: error: stray '\241' in program
0_0_26518299_25619.cpp:4:237: error: 'include' does not name a type
          using namespace std; int main() { char line[105]; while(gets(line)) { int len = strlen(line); if(line[0]!=' ') { line[0] = line[0]-32; } for(int i=1;i<len;i++) { if(line[i]==' ') { line[i+1]-=32; } } puts(line); } return 0; } #include <iostream>
                                                                                                                                                                                                                                             ^
0_0_26518299_25619.cpp: In function 'int main()':
0_0_26518299_25619.cpp:7:35: error: redefinition of 'int main()'
          using namespace std; int main() { char yuan[5] = {'a','e','i','o','u'}; int yuannum[5]; int n; char line[105]; while(cin>>n) { getchar();//此处注意,必须用
                                   ^
0_0_26518299_25619.cpp:4:35: note: 'int main()' previously defined here
          using namespace std; int main() { char line[105]; while(gets(line)) { int len = strlen(line); if(line[0]!=' ') { line[0] = line[0]-32; } for(int i=1;i<len;i++) { if(line[i]==' ') { line[i+1]-=32; } } puts(line); } return 0; } #include <iostream>
                                   ^
0_0_26518299_25619.cpp:8:57: error: expected ';' before 'gets'
         getchar()吃掉一个空字符,否则后面用gets()的时候就会产生错位的现象 for(int k=0;k<n;k++) { memset(yuannum,0,sizeof(yuannum)); gets(line); for(int i=0;i<strlen(line);i++) { for(int j=0;j<5;j++) { if(line[i]==yuan[j]) { yuannum[j]++; } } } for(int i=0;i<5;i++) { cout<<yuan[i]<<":"<<yuannum[i]<<endl; } if(k!=n-1)cout<<endl; } } return 0; }
                                                         ^
0_0_26518299_25619.cpp:8:112: error: 'k' was not declared in this scope
         getchar()吃掉一个空字符,否则后面用gets()的时候就会产生错位的现象 for(int k=0;k<n;k++) { memset(yuannum,0,sizeof(yuannum)); gets(line); for(int i=0;i<strlen(line);i++) { for(int j=0;j<5;j++) { if(line[i]==yuan[j]) { yuannum[j]++; } } } for(int i=0;i<5;i++) { cout<<yuan[i]<<":"<<yuannum[i]<<endl; } if(k!=n-1)cout<<endl; } } return 0; }
                                                                                                                ^


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2024 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2024-12-01 15:35:19, Gzip enabled