結果
問題 |
No.158 奇妙なお使い
|
ユーザー |
👑 |
提出日時 | 2015-02-27 01:17:18 |
言語 | C90 (gcc 12.3.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 456 bytes |
コンパイル時間 | 330 ms |
コンパイル使用メモリ | 22,144 KB |
実行使用メモリ | 44,912 KB |
最終ジャッジ日時 | 2024-06-23 22:06:13 |
合計ジャッジ時間 | 4,380 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 WA * 1 |
other | AC * 18 WA * 9 |
コンパイルメッセージ
main.c:1:1: warning: data definition has no type or storage class 1 | X=1000,Y=100,a,b,c,d[2],e[2],f[2],g[2],p[11][101][10001],s,t,u,v,w,x,y,z; | ^ main.c:1:1: warning: type defaults to ‘int’ in declaration of ‘X’ [-Wimplicit-int] main.c:1:8: warning: type defaults to ‘int’ in declaration of ‘Y’ [-Wimplicit-int] 1 | X=1000,Y=100,a,b,c,d[2],e[2],f[2],g[2],p[11][101][10001],s,t,u,v,w,x,y,z; | ^ main.c:1:14: warning: type defaults to ‘int’ in declaration of ‘a’ [-Wimplicit-int] 1 | X=1000,Y=100,a,b,c,d[2],e[2],f[2],g[2],p[11][101][10001],s,t,u,v,w,x,y,z; | ^ main.c:1:16: warning: type defaults to ‘int’ in declaration of ‘b’ [-Wimplicit-int] 1 | X=1000,Y=100,a,b,c,d[2],e[2],f[2],g[2],p[11][101][10001],s,t,u,v,w,x,y,z; | ^ main.c:1:18: warning: type defaults to ‘int’ in declaration of ‘c’ [-Wimplicit-int] 1 | X=1000,Y=100,a,b,c,d[2],e[2],f[2],g[2],p[11][101][10001],s,t,u,v,w,x,y,z; | ^ main.c:1:20: warning: type defaults to ‘int’ in declaration of ‘d’ [-Wimplicit-int] 1 | X=1000,Y=100,a,b,c,d[2],e[2],f[2],g[2],p[11][101][10001],s,t,u,v,w,x,y,z; | ^ main.c:1:25: warning: type defaults to ‘int’ in declaration of ‘e’ [-Wimplicit-int] 1 | X=1000,Y=100,a,b,c,d[2],e[2],f[2],g[2],p[11][101][10001],s,t,u,v,w,x,y,z; | ^ main.c:1:30: warning: type defaults to ‘int’ in declaration of ‘f’ [-Wimplicit-int] 1 | X=1000,Y=100,a,b,c,d[2],e[2],f[2],g[2],p[11][101][10001],s,t,u,v,w,x,y,z; | ^ main.c:1:35: warning: type defaults to ‘int’ in declaration of ‘g’ [-Wimplicit-int] 1 | X=1000,Y=100,a,b,c,d[2],e[2],f[2],g[2],p[11][101][10001],s,t,u,v,w,x,y,z; | ^ main.c:1:40: warning: type defaults to ‘int’ in declaration of ‘p’ [-Wimplicit-int] 1 | X=1000,Y=100,a,b,c,d[2
ソースコード
X=1000,Y=100,a,b,c,d[2],e[2],f[2],g[2],p[11][101][10001],s,t,u,v,w,x,y,z; _(r){t<r&&(t=r);} main(i){ for(scanf("%d%d%d%d%d%d%d%d%d%d%d",&a,&b,&c,d,e,f,g,d+1,e+1,f+1,g+1);s<10001;++s)for(x=11;x--;)for(y=Y;y;p[x][y--][z]=t){ z=s-x*X-y*Y; t=0; if(z>=0){ y<10||_(p[x+1][y-10][z]); z<Y||_(p[x][y+1][z-Y]); for(i=2;i--;u<0||v<0||w<0||_(1+p[u+e[i]][v+f[i]][w+g[i]]))u=x-d[i]/X,v=y-d[i]/Y%10,w=z-d[i]%Y; } } printf("%d",p[a][b][c]); exit(0); }