結果
問題 | No.750 Frac #1 |
ユーザー |
![]() |
提出日時 | 2019-10-02 07:40:59 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
AC
|
実行時間 | 31 ms / 1,000 ms |
コード長 | 447 bytes |
コンパイル時間 | 363 ms |
コンパイル使用メモリ | 12,672 KB |
実行使用メモリ | 10,880 KB |
最終ジャッジ日時 | 2024-10-03 05:51:05 |
合計ジャッジ時間 | 2,750 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 30 |
ソースコード
def solve(): n = int(input()) numList = [[0 for row in range(3)] for col in range(n)] for i in range(n): line = input().split(" ") nume = int(line[0]) deno = int(line[1]) numList[i][0] = nume / deno numList[i][1] = nume numList[i][2] = deno numList.sort(reverse=True) for j in range(n): ans = str(numList[j][1]) + " " + str(numList[j][2]) print(ans) solve()