結果
問題 |
No.2953 Maximum Right Triangle
|
ユーザー |
|
提出日時 | 2024-11-09 02:16:40 |
言語 | PyPy3 (7.3.15) |
結果 |
WA
|
実行時間 | - |
コード長 | 249 bytes |
コンパイル時間 | 330 ms |
コンパイル使用メモリ | 82,780 KB |
実行使用メモリ | 54,192 KB |
最終ジャッジ日時 | 2024-11-09 02:16:42 |
合計ジャッジ時間 | 1,356 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 1 |
other | AC * 2 WA * 4 |
ソースコード
T=int(input()) for _ in range(T): D,x,y=map(int,input().split()) if x==0: print(D*y) continue if y==0: print(D*x) continue if x+y>D: print(0) continue k=max(int(min((D-y)//x,x//y)),int(min((D-x)//y,y//x))) print(int(k*(x**2+y**2)))