結果

問題 No.1958 Bit Game
ユーザー tailstails
提出日時 2022-05-27 21:49:58
言語 cLay
(20240104-1)
結果
AC  
実行時間 21 ms / 2,000 ms
コード長 313 bytes
コンパイル時間 4,322 ms
コンパイル使用メモリ 180,720 KB
実行使用メモリ 12,728 KB
最終ジャッジ日時 2023-10-20 20:07:32
合計ジャッジ時間 6,360 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 20 ms
12,728 KB
testcase_01 AC 21 ms
12,728 KB
testcase_02 AC 20 ms
12,728 KB
testcase_03 AC 21 ms
12,728 KB
testcase_04 AC 21 ms
12,728 KB
testcase_05 AC 20 ms
12,728 KB
testcase_06 AC 20 ms
12,728 KB
testcase_07 AC 21 ms
12,728 KB
testcase_08 AC 20 ms
12,728 KB
testcase_09 AC 19 ms
12,728 KB
testcase_10 AC 6 ms
9,160 KB
testcase_11 AC 10 ms
10,512 KB
testcase_12 AC 12 ms
11,204 KB
testcase_13 AC 11 ms
10,720 KB
testcase_14 AC 11 ms
10,472 KB
testcase_15 AC 16 ms
11,696 KB
testcase_16 AC 11 ms
10,656 KB
testcase_17 AC 17 ms
12,048 KB
testcase_18 AC 18 ms
12,016 KB
testcase_19 AC 13 ms
11,028 KB
testcase_20 AC 9 ms
10,484 KB
testcase_21 AC 15 ms
11,784 KB
testcase_22 AC 6 ms
9,052 KB
testcase_23 AC 8 ms
10,104 KB
testcase_24 AC 14 ms
11,472 KB
testcase_25 AC 9 ms
10,240 KB
testcase_26 AC 11 ms
10,524 KB
testcase_27 AC 13 ms
11,404 KB
testcase_28 AC 13 ms
11,020 KB
testcase_29 AC 7 ms
9,748 KB
testcase_30 AC 2 ms
7,712 KB
testcase_31 AC 2 ms
7,712 KB
testcase_32 AC 2 ms
7,712 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#define MD 998244353
ll@n,@x,@y,@a[x],@b[y];
Mint z;
rrep(d,18){
	ll e=sum[ll][i,0,x](a[i]&1<<d?1:0);
	ll f=sum[ll][i,0,y](b[i]&1<<d?1:0);
	Matrix<Mint>m1(2,2),m2(2,2);
	m1[0][0]=x;
	m1[0][1]=e;
	m1[1][0]=0;
	m1[1][1]=x-e;
	m2[0][0]=f;
	m2[0][1]=0;
	m2[1][0]=y-f;
	m2[1][1]=y;
	z=z*2+((m2*m1)**n)[0][1];
}
wt(z);
0