結果

問題 No.2560 A_1 < A_2 < ... < A_N
ユーザー titia
提出日時 2023-12-08 03:50:34
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
AC  
実行時間 607 ms / 2,000 ms
コード長 197 bytes
コンパイル時間 249 ms
コンパイル使用メモリ 12,672 KB
実行使用メモリ 18,516 KB
最終ジャッジ日時 2024-09-27 02:37:52
合計ジャッジ時間 5,421 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 1
other AC * 15
権限があれば一括ダウンロードができます

ソースコード

diff #

T=int(input())
for tests in range(T):
    N,X=map(int,input().split())

    if N*(N+1)//2>X:
        print(-1)
        continue

    ANS=list(range(1,N))
    ANS.append(X-sum(ANS))

    print(*ANS)
0