| Run ID | Author | Problem | Lang | Verdict | Score | Time | Memory | Code Length | Submit Time |
|---|---|---|---|---|---|---|---|---|---|
| 3894 | 老师 | 词组缩写 | C++ | Runtime Error | 0 | 0 MS | 248 KB | 371 | 2019-12-26 22:17:31 |
#include<iostream> using namespace std; int main(){ int n; char c[101]; scanf("%d%*c",&n); for(int i=1;i<=n;i++){ gets(c); int j=0; int len=0; while(c[j]!='\0'){ if(c[j]!=' '&&len==0){ if(c[j]>='a') printf("%c",c[j]-32); else printf("%c",c[j]); len++; } if(c[j]==' '){ len=0; } j++; } cout<<endl; } }