結果

問題 No.1423 Triangle of Multiples
ユーザー convexineqconvexineq
提出日時 2021-03-12 21:32:02
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 209 ms / 2,000 ms
コード長 359 bytes
コンパイル時間 171 ms
コンパイル使用メモリ 82,048 KB
実行使用メモリ 77,380 KB
最終ジャッジ日時 2024-10-14 11:42:02
合計ジャッジ時間 1,428 ms
ジャッジサーバーID
(参考情報)
judge4 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 1
other AC * 4
権限があれば一括ダウンロードができます

ソースコード

diff #

def solve(lst):
    a,b,c = lst
    m = min(a,b,c)
    lst.sort()
    if a == m:
        x = (lst[2]-lst[1])//a+1
        a *= x
    if b == m:
        x = (lst[2]-lst[1])//b+1
        b *= x
    if c == m:
        x = (lst[2]-lst[1])//c+1
        c *= x
    return a,b,c

T = int(input())
for _ in range(T):
    print(*solve(list(map(int,input().split()))))
0