結果

問題 No.2352 Sharpened Knife in Fall
ユーザー mkawa2mkawa2
提出日時 2023-06-16 21:56:44
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 384 ms / 3,000 ms
コード長 1,050 bytes
コンパイル時間 367 ms
コンパイル使用メモリ 87,048 KB
実行使用メモリ 81,216 KB
最終ジャッジ日時 2023-09-06 19:37:51
合計ジャッジ時間 12,099 ms
ジャッジサーバーID
(参考情報)
judge14 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 69 ms
71,436 KB
testcase_01 AC 69 ms
71,412 KB
testcase_02 AC 68 ms
71,396 KB
testcase_03 AC 69 ms
71,576 KB
testcase_04 AC 349 ms
81,064 KB
testcase_05 AC 71 ms
71,380 KB
testcase_06 AC 381 ms
81,012 KB
testcase_07 AC 244 ms
79,588 KB
testcase_08 AC 382 ms
81,120 KB
testcase_09 AC 384 ms
81,148 KB
testcase_10 AC 381 ms
81,216 KB
testcase_11 AC 380 ms
81,036 KB
testcase_12 AC 380 ms
81,116 KB
testcase_13 AC 372 ms
81,056 KB
testcase_14 AC 220 ms
79,508 KB
testcase_15 AC 341 ms
80,924 KB
testcase_16 AC 115 ms
77,984 KB
testcase_17 AC 106 ms
78,328 KB
testcase_18 AC 205 ms
80,156 KB
testcase_19 AC 318 ms
80,812 KB
testcase_20 AC 186 ms
79,288 KB
testcase_21 AC 187 ms
79,216 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys

# sys.setrecursionlimit(200005)
# sys.set_int_max_str_digits(1000005)
int1 = lambda x: int(x)-1
pDB = lambda *x: print(*x, end="\n", file=sys.stderr)
p2D = lambda x: print(*x, sep="\n", end="\n\n", file=sys.stderr)
def II(): return int(sys.stdin.readline())
def LI(): return list(map(int, sys.stdin.readline().split()))
def LLI(rows_number): return [LI() for _ in range(rows_number)]
def LI1(): return list(map(int1, sys.stdin.readline().split()))
def LLI1(rows_number): return [LI1() for _ in range(rows_number)]
def SI(): return sys.stdin.readline().rstrip()

dij = [(0, 1), (-1, 0), (0, -1), (1, 0)]
# dij = [(0, 1), (-1, 0), (0, -1), (1, 0), (1, 1), (1, -1), (-1, 1), (-1, -1)]
inf = (1 << 63)-1
# md = 10**9+7
md = 998244353

from math import *

R, k = LI()

cake = R**2*pi
piece = cake/(k+1)

ans = []
for i in range(1, k+1):
    l, r = -pi/2, pi/2
    for _ in range(50):
        m = (l+r)/2
        if (pi/2-m-sin(m)*cos(m))*R*R < piece*i: r = m
        else: l = m
    ans.append(R*sin(l))

for a in ans[::-1]:print(f"{a:.10f}")
0