結果
| 問題 | No.3448 ABBBBBBBBC |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2026-03-23 02:34:06 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
AC
|
| 実行時間 | 333 ms / 2,000 ms |
| コード長 | 558 bytes |
| 記録 | |
| コンパイル時間 | 240 ms |
| コンパイル使用メモリ | 85,120 KB |
| 実行使用メモリ | 83,716 KB |
| 最終ジャッジ日時 | 2026-03-23 02:34:10 |
| 合計ジャッジ時間 | 3,536 ms |
|
ジャッジサーバーID (参考情報) |
judge1_1 / judge3_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 |
| other | AC * 4 |
ソースコード
for _ in range(int(input())): n,k=map(int,input().split()) for i in range(1,10): for j in range(10): if i==j: continue l=j if j>i: l-=1 if l*n<k: k-=l*n else: a,b=(k-1)//l,(k-1)%l if i<j and i<=b: b+=1 print(a+2+1,i,j,b) k=0;break l=9-j if i>j: l-=1 if n*l<k: k-=l*n else: c=l a,b=(k-1)//c,(k-1)%c if i>j and j+1+b>=i: b+=1 print(n-a+2,i,j,j+b+1);k=0 break if not k: break