結果
| 問題 | No.280 歯車の問題(1) |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2020-06-10 08:41:13 |
| 言語 | Python3 (3.14.3 + numpy 2.4.2 + scipy 1.17.0) |
| 結果 |
AC
|
| 実行時間 | 176 ms / 1,000 ms |
| コード長 | 170 bytes |
| 記録 | |
| コンパイル時間 | 514 ms |
| コンパイル使用メモリ | 20,952 KB |
| 実行使用メモリ | 15,616 KB |
| 最終ジャッジ日時 | 2026-03-05 20:39:58 |
| 合計ジャッジ時間 | 7,971 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 31 |
ソースコード
from fractions import Fraction
N = int(input())
Z = tuple(map(int, input().split()))
ans = Fraction(Z[-1], Z[0])
print(ans if ans.denominator != 1 else f'{int(ans)}/1')