Skip to content

Commit

Permalink
add examples
Browse files Browse the repository at this point in the history
  • Loading branch information
zehengl committed May 9, 2024
1 parent 3ed0227 commit df5bdb1
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/afjormun.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
for _ in range(int(input())):
print(input().lower().capitalize())
10 changes: 10 additions & 0 deletions src/bergur.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
n = int(input())
a = [int(d) for d in input().split()]
t = 0
while True:
p = a.index(min(a)) + 1
t += min(a[: p + 1]) * p
a = a[p:]
if not a:
break
print(t)
10 changes: 10 additions & 0 deletions src/cursethedarkness.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
m = int(input())
for _ in range(m):
bx, by = [float(d) for d in input().split()]
n = int(input())
f = False
for _ in range(n):
cx, cy = [float(d) for d in input().split()]
if (bx - cx) ** 2 + (by - cy) ** 2 <= 64:
f = True
print("light a candle" if f else "curse the darkness")

0 comments on commit df5bdb1

Please sign in to comment.