結果

問題 No.1794 Continued Fraction
ユーザー chineristACchineristAC
提出日時 2021-12-23 00:18:29
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 271 ms / 2,000 ms
コード長 391 bytes
コンパイル時間 468 ms
コンパイル使用メモリ 87,036 KB
実行使用メモリ 93,272 KB
最終ジャッジ日時 2023-10-15 02:55:05
合計ジャッジ時間 10,998 ms
ジャッジサーバーID
(参考情報)
judge12 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 258 ms
92,688 KB
testcase_01 AC 259 ms
92,896 KB
testcase_02 AC 255 ms
93,052 KB
testcase_03 AC 256 ms
92,824 KB
testcase_04 AC 259 ms
93,124 KB
testcase_05 AC 258 ms
92,856 KB
testcase_06 AC 263 ms
93,148 KB
testcase_07 AC 260 ms
92,780 KB
testcase_08 AC 258 ms
93,048 KB
testcase_09 AC 256 ms
93,044 KB
testcase_10 AC 264 ms
93,044 KB
testcase_11 AC 256 ms
93,120 KB
testcase_12 AC 257 ms
93,044 KB
testcase_13 AC 257 ms
93,032 KB
testcase_14 AC 263 ms
92,868 KB
testcase_15 AC 257 ms
92,940 KB
testcase_16 AC 257 ms
93,040 KB
testcase_17 AC 271 ms
92,936 KB
testcase_18 AC 262 ms
92,920 KB
testcase_19 AC 264 ms
92,936 KB
testcase_20 AC 264 ms
92,920 KB
testcase_21 AC 262 ms
92,988 KB
testcase_22 AC 261 ms
93,060 KB
testcase_23 AC 260 ms
93,128 KB
testcase_24 AC 259 ms
93,272 KB
testcase_25 AC 259 ms
92,924 KB
testcase_26 AC 259 ms
93,172 KB
testcase_27 AC 256 ms
92,916 KB
testcase_28 AC 258 ms
92,864 KB
testcase_29 AC 254 ms
93,044 KB
testcase_30 AC 257 ms
93,148 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys,random,bisect
from collections import deque,defaultdict
from heapq import heapify,heappop,heappush
from itertools import permutations
from math import log,gcd
from fractions import Fraction

input = lambda :sys.stdin.readline().rstrip()
mi = lambda :map(int,input().split())
li = lambda :list(mi())

N,M = mi()
A = []
while M:
    A.append(N//M)
    N %= M
    N,M = M,N
print(*A)
0