結果

問題 No.746 7の倍数
ユーザー GrayCoderGrayCoder
提出日時 2023-06-17 18:46:34
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 172 ms / 2,000 ms
コード長 795 bytes
コンパイル時間 99 ms
コンパイル使用メモリ 10,688 KB
実行使用メモリ 8,432 KB
最終ジャッジ日時 2023-09-07 14:56:57
合計ジャッジ時間 3,075 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 16 ms
7,960 KB
testcase_01 AC 16 ms
7,912 KB
testcase_02 AC 16 ms
8,000 KB
testcase_03 AC 172 ms
8,432 KB
testcase_04 AC 16 ms
7,860 KB
testcase_05 AC 19 ms
7,876 KB
testcase_06 AC 43 ms
8,404 KB
testcase_07 AC 30 ms
8,208 KB
testcase_08 AC 47 ms
8,228 KB
testcase_09 AC 29 ms
8,220 KB
testcase_10 AC 18 ms
7,864 KB
testcase_11 AC 95 ms
8,380 KB
testcase_12 AC 172 ms
8,396 KB
testcase_13 AC 67 ms
8,352 KB
testcase_14 AC 88 ms
8,296 KB
testcase_15 AC 75 ms
8,344 KB
testcase_16 AC 83 ms
8,240 KB
testcase_17 AC 75 ms
8,388 KB
testcase_18 AC 87 ms
8,348 KB
testcase_19 AC 73 ms
8,348 KB
testcase_20 AC 30 ms
8,192 KB
testcase_21 AC 22 ms
7,780 KB
testcase_22 AC 114 ms
8,392 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

"""
from math import gcd
from itertools import accumulate, combinations, permutations, product
from bisect import bisect, bisect_left
from collections import Counter, defaultdict, deque
from heapq import heappush, heappop
from functools import reduce
from operator import add, mul, sub, truediv, floordiv, mod

from decimal import *
getcontext().prec = 500

import string
ascii = string.ascii_lowercase
"""

import sys


def main():
    sys.setrecursionlimit(100000)
    sys.set_int_max_str_digits(100000)
    input = lambda: sys.stdin.readline()[:-1]
    N = int(input())

    n = 10**N
    d, m = divmod(n // 7, n)
    if m:
        ans = "".join([str(d), ".", str(m)])
    else:
        ans = str(d)
    print(ans)


if not __debug__:
    f = open(sys.argv[1], "r")
    sys.stdin = f

main()
0