Skip to content

Commit 0089e70

Browse files
author
IsHYuhi
committed
ARC52-ARC57
1 parent fb69e0d commit 0089e70

File tree

7 files changed

+52
-17
lines changed

7 files changed

+52
-17
lines changed

ARC/ARC052/A.py

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
s = input()
2+
num = [i for i in s if ord('0')<=ord(i)<=ord('9')]
3+
print(''.join(num))

ARC/ARC053/A.py

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
h, w = map(int, input().split())
2+
print((h-1)*w + (w-1)*h)

ARC/ARC054/A.py

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
l, x, y, s, d = map(int, input().split())
2+
3+
speed_n = x+y
4+
speed_b = 0 if x-y>0 else -(x-y)
5+
6+
if s<=d:
7+
print(min((d-s)/speed_n if speed_n != 0 else float('inf'), (l-d+s)/speed_b if speed_b != 0 else float('inf')))
8+
else:
9+
print(min((l-s+d)/speed_n if speed_n != 0 else float('inf'), (s-d)/speed_b if speed_b != 0 else float('inf')))

ARC/ARC055/A.py

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
n = int(input())
2+
print(10**n+7)

ARC/ARC056/A.py

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
a, b, k, l = map(int, input().split())
2+
3+
if a < b/l:
4+
print(k*a)
5+
else:
6+
print(min( a*(k-l*(k//l))+b*(k//l), b*(k//l+1)))

ARC/ARC057/A.py

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
a, k = map(int, input().split())
2+
3+
i = 0
4+
an = a
5+
6+
if k == 0:
7+
print(int(2*1e12-a))
8+
exit()
9+
10+
while an<2*1e12:
11+
an += k*an + 1
12+
i += 1
13+
print(i)

README.md

+17-17
Original file line numberDiff line numberDiff line change
@@ -137,11 +137,11 @@ AtCoderの問題をpython3で解いたものになります。AC確認は行っ
137137
### ARC001 - ARC103
138138
|コンテスト| A | B | C | D ||コンテスト| A | B | C | D |
139139
|:---:|:---:|:---:|:---:|:---:|:---:|:---:|:---:|:---:|:---:|:---:|
140-
|[ARC001](ARC/ARC001)|[&check;](ARC/ARC001/A.py)|[&check;](ARC/ARC001/B.py)| - | - ||[ARC053](ARC/ARC053)| - | - | - | - |
141-
|[ARC002](ARC/ARC002)|[&check;](ARC/ARC002/A.py)|[&check;](ARC/ARC002/B.py)| - | - ||[ARC054](ARC/ARC054)| - | - | - | - |
142-
|[ARC003](ARC/ARC003)|[&check;](ARC/ARC003/A.py)|[&check;](ARC/ARC003/B.py)| - | - ||[ARC055](ARC/ARC055)| - | - | - | - |
143-
|[ARC004](ARC/ARC004)|[&check;](ARC/ARC004/A.py)| - | - | - ||[ARC056](ARC/ARC056)| - | - | - | - |
144-
|[ARC005](ARC/ARC005)|[&check;](ARC/ARC005/A.py)| - | - | - ||[ARC057](ARC/ARC057)| - | - | - | - |
140+
|[ARC001](ARC/ARC001)|[&check;](ARC/ARC001/A.py)|[&check;](ARC/ARC001/B.py)| - | - ||[ARC053](ARC/ARC053)|[&check;](ARC/ARC053/A.py)| - | - | - |
141+
|[ARC002](ARC/ARC002)|[&check;](ARC/ARC002/A.py)|[&check;](ARC/ARC002/B.py)| - | - ||[ARC054](ARC/ARC054)|[&check;](ARC/ARC054/A.py)| - | - | - |
142+
|[ARC003](ARC/ARC003)|[&check;](ARC/ARC003/A.py)|[&check;](ARC/ARC003/B.py)| - | - ||[ARC055](ARC/ARC055)|[&check;](ARC/ARC055/A.py)| - | - | - |
143+
|[ARC004](ARC/ARC004)|[&check;](ARC/ARC004/A.py)| - | - | - ||[ARC056](ARC/ARC056)|[&check;](ARC/ARC056/A.py)| - | - | - |
144+
|[ARC005](ARC/ARC005)|[&check;](ARC/ARC005/A.py)| - | - | - ||[ARC057](ARC/ARC057)|[&check;](ARC/ARC057/A.py)| - | - | - |
145145
|[ARC006](ARC/ARC006)|[&check;](ARC/ARC006/A.py)|[&check;](ARC/ARC006/B.py)| - | - ||[ARC058](ARC/ARC058)| - | - | - | - |
146146
|[ARC007](ARC/ARC007)|[&check;](ARC/ARC007/A.py)|[&check;](ARC/ARC007/B.py)| - | - ||[ARC059](ARC/ARC059)|[&check;](ARC/ARC059/A.py)| - | - | - |
147147
|[ARC008](ARC/ARC008)|[&check;](ARC/ARC008/A.py)|[&check;](ARC/ARC008/B.py)| - | - ||[ARC060](ARC/ARC060)| - | - | - | - |
@@ -177,18 +177,18 @@ AtCoderの問題をpython3で解いたものになります。AC確認は行っ
177177
|[ARC038](ARC/ARC038)|[&check;](ARC/ARC038/A.py)| - | - | - ||[ARC090](ARC/ARC090)|[&check;](ARC/ARC090/A.py)| - | - | - |
178178
|[ARC039](ARC/ARC039)|[&check;](ARC/ARC039/A.py)| - | - | - ||[ARC091](ARC/ARC091)|[&check;](ARC/ARC091/A.py)| - | - | - |
179179
|[ARC040](ARC/ARC040)|[&check;](ARC/ARC040/A.py)| - | - | - ||[ARC092](ARC/ARC092)| - | - | - | - |
180-
|[ARC041](ARC/ARC041)| - | - | - | - ||[ARC093](ARC/ARC093)|[&check;](ARC/ARC093/A.py)| - | - | - |
181-
|[ARC042](ARC/ARC042)| - | - | - | - ||[ARC094](ARC/ARC094)|[&check;](ARC/ARC094/A.py)| - | - | - |
182-
|[ARC043](ARC/ARC043)| - | - | - | - ||[ARC095](ARC/ARC095)|[&check;](ARC/ARC095/A.py)| - | - | - |
183-
|[ARC044](ARC/ARC044)| - | - | - | - ||[ARC096](ARC/ARC096)|[&check;](ARC/ARC096/A.py)| - | - | - |
184-
|[ARC045](ARC/ARC045)| - | - | - | - ||[ARC097](ARC/ARC097)| - | - | - | - |
185-
|[ARC046](ARC/ARC046)| - | - | - | - ||[ARC098](ARC/ARC098)|[&check;](ARC/ARC098/A.py)| - | - | - |
186-
|[ARC047](ARC/ARC047)| - | - | - | - ||[ARC099](ARC/ARC099)|[&check;](ARC/ARC099/A.py)| - | - | - |
187-
|[ARC048](ARC/ARC048)| - | - | - | - ||[ARC100](ARC/ARC100)| - | - | - | - |
188-
|[ARC049](ARC/ARC049)| - | - | - | - ||[ARC101](ARC/ARC101)| - | - | - | - |
189-
|[ARC050](ARC/ARC050)| - | - | - | - ||[ARC102](ARC/ARC102)| - | - | - | - |
190-
|[ARC051](ARC/ARC051)| - | - | - | - ||[ARC103](ARC/ARC103)|[&check;](ARC/ARC103/A.py)| - | - | - |
191-
|[ARC052](ARC/ARC052)| - | - | - | - |||||||
180+
|[ARC041](ARC/ARC041)|[&check;](ARC/ARC041/A.py)| - | - | - ||[ARC093](ARC/ARC093)|[&check;](ARC/ARC093/A.py)| - | - | - |
181+
|[ARC042](ARC/ARC042)|| - | - | - ||[ARC094](ARC/ARC094)|[&check;](ARC/ARC094/A.py)| - | - | - |
182+
|[ARC043](ARC/ARC043)|| - | - | - ||[ARC095](ARC/ARC095)|[&check;](ARC/ARC095/A.py)| - | - | - |
183+
|[ARC044](ARC/ARC044)|[&check;](ARC/ARC044/A.py)| - | - | - ||[ARC096](ARC/ARC096)|[&check;](ARC/ARC096/A.py)| - | - | - |
184+
|[ARC045](ARC/ARC045)|[&check;](ARC/ARC045/A.py)| - | - | - ||[ARC097](ARC/ARC097)| - | - | - | - |
185+
|[ARC046](ARC/ARC046)|[&check;](ARC/ARC046/A.py)| - | - | - ||[ARC098](ARC/ARC098)|[&check;](ARC/ARC098/A.py)| - | - | - |
186+
|[ARC047](ARC/ARC047)|[&check;](ARC/ARC047/A.py)| - | - | - ||[ARC099](ARC/ARC099)|[&check;](ARC/ARC099/A.py)| - | - | - |
187+
|[ARC048](ARC/ARC048)|[&check;](ARC/ARC048/A.py)| - | - | - ||[ARC100](ARC/ARC100)| - | - | - | - |
188+
|[ARC049](ARC/ARC049)|[&check;](ARC/ARC049/A.py)| - | - | - ||[ARC101](ARC/ARC101)| - | - | - | - |
189+
|[ARC050](ARC/ARC050)|[&check;](ARC/ARC050/A.py)| - | - | - ||[ARC102](ARC/ARC102)| - | - | - | - |
190+
|[ARC051](ARC/ARC051)|[&check;](ARC/ARC051/A.py)| - | - | - ||[ARC103](ARC/ARC103)|[&check;](ARC/ARC103/A.py)| - | - | - |
191+
|[ARC052](ARC/ARC052)|[&check;](ARC/ARC052/A.py)| - | - | - |||||||
192192

193193

194194
### ARC108 -

0 commit comments

Comments
 (0)