結果

問題 No.1738 What's in the box?
ユーザー dn6049949dn6049949
提出日時 2021-11-14 21:45:18
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 123 ms / 2,000 ms
コード長 623 bytes
コンパイル時間 678 ms
コンパイル使用メモリ 86,848 KB
実行使用メモリ 76,628 KB
最終ジャッジ日時 2023-08-20 06:27:27
合計ジャッジ時間 11,440 ms
ジャッジサーバーID
(参考情報)
judge11 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 109 ms
71,428 KB
testcase_01 AC 113 ms
71,828 KB
testcase_02 AC 117 ms
71,436 KB
testcase_03 AC 121 ms
76,060 KB
testcase_04 AC 117 ms
76,376 KB
testcase_05 AC 122 ms
76,160 KB
testcase_06 AC 117 ms
76,040 KB
testcase_07 AC 121 ms
76,576 KB
testcase_08 AC 122 ms
76,476 KB
testcase_09 AC 120 ms
76,000 KB
testcase_10 AC 120 ms
76,388 KB
testcase_11 AC 122 ms
76,616 KB
testcase_12 AC 122 ms
75,992 KB
testcase_13 AC 113 ms
71,460 KB
testcase_14 AC 114 ms
71,624 KB
testcase_15 AC 111 ms
71,808 KB
testcase_16 AC 114 ms
71,408 KB
testcase_17 AC 113 ms
71,532 KB
testcase_18 AC 112 ms
71,812 KB
testcase_19 AC 112 ms
71,576 KB
testcase_20 AC 110 ms
71,496 KB
testcase_21 AC 114 ms
71,840 KB
testcase_22 AC 113 ms
71,408 KB
testcase_23 AC 112 ms
71,580 KB
testcase_24 AC 113 ms
71,752 KB
testcase_25 AC 114 ms
71,432 KB
testcase_26 AC 114 ms
71,640 KB
testcase_27 AC 107 ms
71,576 KB
testcase_28 AC 111 ms
71,436 KB
testcase_29 AC 107 ms
71,696 KB
testcase_30 AC 100 ms
71,528 KB
testcase_31 AC 96 ms
71,852 KB
testcase_32 AC 99 ms
71,580 KB
testcase_33 AC 99 ms
72,304 KB
testcase_34 AC 100 ms
76,204 KB
testcase_35 AC 100 ms
72,168 KB
testcase_36 AC 106 ms
72,412 KB
testcase_37 AC 108 ms
72,184 KB
testcase_38 AC 123 ms
76,180 KB
testcase_39 AC 114 ms
72,256 KB
testcase_40 AC 118 ms
76,388 KB
testcase_41 AC 120 ms
76,172 KB
testcase_42 AC 120 ms
76,052 KB
testcase_43 AC 119 ms
76,472 KB
testcase_44 AC 123 ms
75,992 KB
testcase_45 AC 123 ms
76,628 KB
testcase_46 AC 120 ms
76,164 KB
testcase_47 AC 119 ms
76,156 KB
testcase_48 AC 118 ms
76,356 KB
testcase_49 AC 120 ms
76,360 KB
testcase_50 AC 119 ms
76,164 KB
testcase_51 AC 120 ms
76,184 KB
testcase_52 AC 118 ms
75,988 KB
testcase_53 AC 109 ms
71,588 KB
testcase_54 AC 109 ms
71,576 KB
testcase_55 AC 108 ms
71,272 KB
testcase_56 AC 114 ms
71,840 KB
testcase_57 AC 112 ms
71,528 KB
testcase_58 AC 111 ms
71,800 KB
testcase_59 AC 97 ms
71,576 KB
testcase_60 AC 94 ms
71,452 KB
testcase_61 AC 98 ms
71,892 KB
testcase_62 AC 94 ms
71,504 KB
testcase_63 AC 95 ms
71,828 KB
testcase_64 AC 96 ms
71,768 KB
testcase_65 AC 98 ms
71,688 KB
testcase_66 AC 97 ms
71,384 KB
testcase_67 AC 97 ms
71,892 KB
testcase_68 AC 95 ms
71,800 KB
testcase_69 AC 96 ms
71,648 KB
testcase_70 AC 95 ms
71,808 KB
testcase_71 AC 96 ms
71,564 KB
testcase_72 AC 94 ms
71,760 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#!usr/bin/env python3
from collections import defaultdict, deque
from heapq import heappush, heappop
from itertools import permutations, accumulate
import sys
import math
import bisect
def LI(): return [int(x) for x in sys.stdin.readline().split()]
def I(): return int(sys.stdin.readline())
def IR(n):
    return [I() for _ in range(n)]
def LIR(n):
    return [LI() for _ in range(n)]

sys.setrecursionlimit(1000000)
mod = 1000000007

def main():
    n,m = LI()
    w = LI()
    s = sum(w)
    if s == 0:
        print(*w)
        return
    print(*[(m*i)//s for i in w])
    return


if __name__ == "__main__":
    main()
0