結果
問題 | No.457 (^^*) |
ユーザー |
👑 ![]() |
提出日時 | 2016-12-31 11:21:49 |
言語 | C90 (gcc 12.3.0) |
結果 |
AC
|
実行時間 | 190 ms / 2,000 ms |
コード長 | 268 bytes |
コンパイル時間 | 128 ms |
コンパイル使用メモリ | 20,480 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-12-16 04:22:12 |
合計ジャッジ時間 | 1,800 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 20 |
コンパイルメッセージ
main.c:1:8: warning: multi-character character constant [-Wmultichar] 1 | char s['~~'];i,j,L,R,tL,tR,sL,sR; | ^~~~ main.c:1:14: warning: data definition has no type or storage class 1 | char s['~~'];i,j,L,R,tL,tR,sL,sR; | ^ main.c:1:14: warning: type defaults to ‘int’ in declaration of ‘i’ [-Wimplicit-int] main.c:1:16: warning: type defaults to ‘int’ in declaration of ‘j’ [-Wimplicit-int] 1 | char s['~~'];i,j,L,R,tL,tR,sL,sR; | ^ main.c:1:18: warning: type defaults to ‘int’ in declaration of ‘L’ [-Wimplicit-int] 1 | char s['~~'];i,j,L,R,tL,tR,sL,sR; | ^ main.c:1:20: warning: type defaults to ‘int’ in declaration of ‘R’ [-Wimplicit-int] 1 | char s['~~'];i,j,L,R,tL,tR,sL,sR; | ^ main.c:1:22: warning: type defaults to ‘int’ in declaration of ‘tL’ [-Wimplicit-int] 1 | char s['~~'];i,j,L,R,tL,tR,sL,sR; | ^~ main.c:1:25: warning: type defaults to ‘int’ in declaration of ‘tR’ [-Wimplicit-int] 1 | char s['~~'];i,j,L,R,tL,tR,sL,sR; | ^~ main.c:1:28: warning: type defaults to ‘int’ in declaration of ‘sL’ [-Wimplicit-int] 1 | char s['~~'];i,j,L,R,tL,tR,sL,sR; | ^~ main.c:1:31: warning: type defaults to ‘int’ in declaration of ‘sR’ [-Wimplicit-int] 1 | char s['~~'];i,j,L,R,tL,tR,sL,sR; | ^~ main.c:2:1: warning: return type defaults to ‘int’ [-Wimplicit-int] 2 | main(){ | ^~~~ main.c: In function ‘main’: main.c:3:13: warning: implicit declaration of function ‘gets’ [-Wimplicit-function-declaration] 3 | for(gets(s);s[i]=='('&&s[++j]? | ^~~~ main.c:7:12: warning: implicit declaration of function ‘printf’ [-Wimplicit-function-declaration] 7 | i=!printf("%d %d",sL,sR); | ^~~~~~
ソースコード
char s['~~'];i,j,L,R,tL,tR,sL,sR;main(){for(gets(s);s[i]=='('&&s[++j]?tL<2&s[j]=='^'|tL==2&s[j]=='*'?++tL:s[j]==')'?tL+=tL>2,sL+=tL>3:0,tR<3&tR>0&s[j]=='^'|!tR&s[j]=='*'?++tR:s[j]==')'?tR+=tR>2,sR+=tR>3:0,1:(tL=tR=0,s[j=++i]););i=!printf("%d %d",sL,sR);}