結果
| 問題 | No.832 麻雀修行中 |
| コンテスト | |
| ユーザー |
👑 tails
|
| 提出日時 | 2020-12-21 19:51:25 |
| 言語 | C(gnu17) (gcc 15.2.0) |
| 結果 |
CE
(最新)
AC
(最初)
|
| 実行時間 | - |
| コード長 | 404 bytes |
| 記録 | |
| コンパイル時間 | 145 ms |
| コンパイル使用メモリ | 28,540 KB |
| 最終ジャッジ日時 | 2026-02-22 06:35:58 |
|
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
コンパイルエラー時のメッセージ・ソースコードは、提出者また管理者しか表示できないようにしております。(リジャッジ後のコンパイルエラーは公開されます)
ただし、clay言語の場合は開発者のデバッグのため、公開されます。
ただし、clay言語の場合は開発者のデバッグのため、公開されます。
コンパイルメッセージ
main.c:4:1: error: return type defaults to 'int' [-Wimplicit-int]
4 | main(){
| ^~~~
main.c: In function 'main':
main.c:6:17: error: implicit declaration of function 'getchar' [-Wimplicit-function-declaration]
6 | while(s=getchar()-49,s>=0){
| ^~~~~~~
main.c:1:1: note: 'getchar' is defined in header '<stdio.h>'; this is probably fixable by adding '#include <stdio.h>'
+++ |+#include <stdio.h>
1 | #pragma GCC optimize("Ofast")
main.c:22:25: error: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
22 | printf("%d\n",t+1);
| ^~~~~~
main.c:22:25: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:22:25: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
main.c:22:25: note: include '<stdio.h>' or provide a declaration of 'printf'
ソースコード
#pragma GCC optimize("Ofast")
#pragma GCC target("avx2")
main(){
int a=0,s;
while(s=getchar()-49,s>=0){
a+=1<<s*3;
}
for(int t=0;t<9;++t){
int b=a+(1<<t*3);
int o=b&0555555555;
for(int h=1;h<<5;h<<=3){
if(b&h*6){
int c=b-h*2;
do{
c=c+1&4?c-3:~(c|c>>1|c>>2)&73?c&7?1:c>>3:c-73;
}while(c>1);
o*=c;
}
}
if(!(o|b&b>>2&0111111111)){
printf("%d\n",t+1);
}
}
}
tails