結果
問題 |
No.1738 What's in the box?
|
ユーザー |
![]() |
提出日時 | 2021-11-14 20:23:27 |
言語 | PyPy3 (7.3.15) |
結果 |
WA
|
実行時間 | - |
コード長 | 1,128 bytes |
コンパイル時間 | 255 ms |
コンパイル使用メモリ | 82,560 KB |
実行使用メモリ | 80,640 KB |
最終ジャッジ日時 | 2024-11-30 04:34:35 |
合計ジャッジ時間 | 9,424 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | WA * 68 RE * 2 |
ソースコード
#!/usr/bin/env python3 from pprint import pprint from sys import setrecursionlimit, stdin from typing import Dict, Iterable, Set INF: int = 1 << 62 MOD1000000007 = 10**9 + 7 MOD998244353 = 998244353 setrecursionlimit(1_000_000) def inputs(type_=int): ins = input().split() if isinstance(type_, Iterable): return [t(x) for t, x in zip(type_, ins)] else: return list(map(type_, ins)) def input_(type_=int): a, = inputs(type_) return a def input1() -> int: return int(input()) inputi = input1 def input2(): a, b = input().split() return int(a), int(b) def input3(): a, b, c = input().split() return int(a), int(b), int(c) def input4(): a, b, c, d = input().split() return int(a), int(b), int(c), int(d) def answer(res) -> None: print(res) exit() # start coding n, m = input2() cnts = inputs() s = sum(cnts) if m >= s: w = m // s res = [] for c in cnts: res.append(c*w) # print(s, w) print(*res) else: w = s // m res = [] for c in cnts: res.append(c // w) # print(s, w) print(*res)