Submission #7921593
Source Code Expand
r,n,m = map(int, input().split()) ans = 0 for i in range(1,n+m): a = 1-(1-(2*i)/n)**2 b = 1-(1-(2*(i-m))/n)**2 if a<=0: ans += b**0.5 elif b<=0: ans += a**0.5 else: ans += max(a**0.5,b**0.5) print(ans*2*r)
Submission Info
Submission Time | |
---|---|
Task | B - ステップカット |
User | psmf1 |
Language | PyPy3 (2.4.0) |
Score | 200 |
Code Size | 268 Byte |
Status | AC |
Exec Time | 201 ms |
Memory | 39920 KB |
Judge Result
Set Name | Sample | All | ||||
---|---|---|---|---|---|---|
Score / Max Score | 0 / 0 | 200 / 200 | ||||
Status |
|
|
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 | 165 ms | 38256 KB |
00_example_02.txt | AC | 167 ms | 38256 KB |
00_example_03.txt | AC | 201 ms | 39536 KB |
10_rand_01.txt | AC | 164 ms | 38256 KB |
10_rand_02.txt | AC | 163 ms | 38256 KB |
10_rand_03.txt | AC | 188 ms | 39920 KB |
10_rand_04.txt | AC | 169 ms | 38256 KB |
10_rand_05.txt | AC | 175 ms | 39152 KB |
10_rand_06.txt | AC | 176 ms | 39280 KB |
10_rand_07.txt | AC | 178 ms | 39408 KB |
10_rand_08.txt | AC | 181 ms | 39920 KB |
20_hand_01.txt | AC | 192 ms | 39152 KB |
20_hand_02.txt | AC | 193 ms | 39024 KB |
20_hand_03.txt | AC | 193 ms | 39152 KB |
20_hand_04.txt | AC | 164 ms | 38256 KB |
20_hand_05.txt | AC | 164 ms | 38256 KB |