Submission #6935318


Source Code Expand

r, n, m = map(int, input().split())

def cut_len(i):
    if 1 <= i <= n-1:
        return 2 * r * (1 - (abs(n/2-i) / (n/2)) ** 2) ** .5
    else:
        return 0

ans = 0
for i in range(1, n+m):
    ans += max(cut_len(i), cut_len(i-m))
print(ans)

Submission Info

Submission Time
Task B - ステップカット
User miozune
Language Python (3.4.3)
Score 200
Code Size 260 Byte
Status AC
Exec Time 289 ms
Memory 3064 KB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 200 / 200
Status
AC × 3
AC × 16
Set Name Test Cases
Sample 00_example_01.txt, 00_example_02.txt, 00_example_03.txt
All 00_example_01.txt, 00_example_02.txt, 00_example_03.txt, 10_rand_01.txt, 10_rand_02.txt, 10_rand_03.txt, 10_rand_04.txt, 10_rand_05.txt, 10_rand_06.txt, 10_rand_07.txt, 10_rand_08.txt, 20_hand_01.txt, 20_hand_02.txt, 20_hand_03.txt, 20_hand_04.txt, 20_hand_05.txt
Case Name Status Exec Time Memory
00_example_01.txt AC 17 ms 2940 KB
00_example_02.txt AC 17 ms 3060 KB
00_example_03.txt AC 215 ms 2940 KB
10_rand_01.txt AC 17 ms 2940 KB
10_rand_02.txt AC 17 ms 2940 KB
10_rand_03.txt AC 109 ms 2940 KB
10_rand_04.txt AC 19 ms 2940 KB
10_rand_05.txt AC 28 ms 2940 KB
10_rand_06.txt AC 22 ms 2940 KB
10_rand_07.txt AC 54 ms 2940 KB
10_rand_08.txt AC 38 ms 2940 KB
20_hand_01.txt AC 206 ms 2940 KB
20_hand_02.txt AC 289 ms 3064 KB
20_hand_03.txt AC 218 ms 2940 KB
20_hand_04.txt AC 17 ms 2940 KB
20_hand_05.txt AC 17 ms 2940 KB