結果
問題 | No.2560 A_1 < A_2 < ... < A_N |
ユーザー |
|
提出日時 | 2023-12-02 15:15:12 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 308 ms / 2,000 ms |
コード長 | 800 bytes |
コンパイル時間 | 395 ms |
コンパイル使用メモリ | 82,132 KB |
実行使用メモリ | 88,852 KB |
最終ジャッジ日時 | 2024-09-26 18:20:10 |
合計ジャッジ時間 | 3,802 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 1 |
other | AC * 15 |
ソースコード
import sys if sys.platform =='ios': import clipboard a=clipboard.get() a = a.split('\n') text = '\n'.join(a) with open('input_file.txt','w') as f: f.write(text) sys.stdin = open('input_file.txt') sys.setrecursionlimit(410000000) stdin = sys.stdin def ni():return int(ns()) def na():return list(map(int, stdin.readline().split())) def ns():return stdin.readline().strip() def nm():return map(int,input().split()) def na_1():return list(map(lambda x:int(x)*(-1), stdin.readline().split())) def na_2():return list(map(lambda x:int(x)-1, stdin.readline().split())) rnage=range rnge=range rage = range t = ni() for i in range(t): N,X = nm() k = N*(N+1)//2 if k > X: print(-1) else: ans = [] tot = 0 for i in range(1,N): ans.append(i) tot += i ans.append(X-tot) print(*ans)