結果
| 問題 | No.321 (P,Q)-サンタと街の子供たち |
| コンテスト | |
| ユーザー |
testestest
|
| 提出日時 | 2016-03-31 20:18:06 |
| 言語 | C90 (gcc 12.3.0) |
| 結果 |
AC
|
| 実行時間 | 23 ms / 2,000 ms |
| コード長 | 155 bytes |
| 記録 | |
| コンパイル時間 | 97 ms |
| コンパイル使用メモリ | 19,840 KB |
| 実行使用メモリ | 6,944 KB |
| 最終ジャッジ日時 | 2024-07-06 22:11:36 |
| 合計ジャッジ時間 | 1,846 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | AC * 41 |
コンパイルメッセージ
main.c:1:1: warning: data definition has no type or storage class
1 | s,p,q,x,y;main(f){for(scanf("%d%d%d",&p,&q,&s),y=p,f=q;x=y;f=x)y=f%x;for(;~scanf("%d%d",&x,&y);s-=f?x%f|y%f||(x+y)/f&!((p+q)/f%2):x||y);s=!printf("%d",s);}
| ^
main.c:1:1: warning: type defaults to ‘int’ in declaration of ‘s’ [-Wimplicit-int]
main.c:1:3: warning: type defaults to ‘int’ in declaration of ‘p’ [-Wimplicit-int]
1 | s,p,q,x,y;main(f){for(scanf("%d%d%d",&p,&q,&s),y=p,f=q;x=y;f=x)y=f%x;for(;~scanf("%d%d",&x,&y);s-=f?x%f|y%f||(x+y)/f&!((p+q)/f%2):x||y);s=!printf("%d",s);}
| ^
main.c:1:5: warning: type defaults to ‘int’ in declaration of ‘q’ [-Wimplicit-int]
1 | s,p,q,x,y;main(f){for(scanf("%d%d%d",&p,&q,&s),y=p,f=q;x=y;f=x)y=f%x;for(;~scanf("%d%d",&x,&y);s-=f?x%f|y%f||(x+y)/f&!((p+q)/f%2):x||y);s=!printf("%d",s);}
| ^
main.c:1:7: warning: type defaults to ‘int’ in declaration of ‘x’ [-Wimplicit-int]
1 | s,p,q,x,y;main(f){for(scanf("%d%d%d",&p,&q,&s),y=p,f=q;x=y;f=x)y=f%x;for(;~scanf("%d%d",&x,&y);s-=f?x%f|y%f||(x+y)/f&!((p+q)/f%2):x||y);s=!printf("%d",s);}
| ^
main.c:1:9: warning: type defaults to ‘int’ in declaration of ‘y’ [-Wimplicit-int]
1 | s,p,q,x,y;main(f){for(scanf("%d%d%d",&p,&q,&s),y=p,f=q;x=y;f=x)y=f%x;for(;~scanf("%d%d",&x,&y);s-=f?x%f|y%f||(x+y)/f&!((p+q)/f%2):x||y);s=!printf("%d",s);}
| ^
main.c:1:11: warning: return type defaults to ‘int’ [-Wimplicit-int]
1 | s,p,q,x,y;main(f){for(scanf("%d%d%d",&p,&q,&s),y=p,f=q;x=y;f=x)y=f%x;for(;~scanf("%d%d",&x,&y);s-=f?x%f|y%f||(x+y)/f&!((p+q)/f%2):x||y);s=!printf("%d",s);}
| ^~~~
main.c: In function ‘main’:
main.c:1:11: warning: type of ‘f’ defaults to ‘int’ [-Wimplicit-int]
main.c:1:23: warning: implicit declaration of function ‘scanf’ [-Wimplicit-function-declaration]
1 | s,p,q,x,y;main(f){for(scanf("%d%d%d",&p,&q,&s),y=p,f=q;x=y;f=x)y=f%x;for(;~scanf("%d%d",&x,&y);s-=f?x%f|y%f||(x
ソースコード
s,p,q,x,y;main(f){for(scanf("%d%d%d",&p,&q,&s),y=p,f=q;x=y;f=x)y=f%x;for(;~scanf("%d%d",&x,&y);s-=f?x%f|y%f||(x+y)/f&!((p+q)/f%2):x||y);s=!printf("%d",s);}
testestest