mirror of
https://github.com/Oxbian/CodingGame.git
synced 2025-07-07 04:14:27 +02:00
Adding python files
This commit is contained in:
11
Python/Easy_Challenges/onboarding.py
Normal file
11
Python/Easy_Challenges/onboarding.py
Normal file
@ -0,0 +1,11 @@
|
||||
# game loop
|
||||
while 1:
|
||||
enemy_1 = input() # name of enemy 1
|
||||
dist_1 = int(input()) # distance to enemy 1
|
||||
enemy_2 = input() # name of enemy 2
|
||||
dist_2 = int(input()) # distance to enemy 2
|
||||
|
||||
if (dist_1 < dist_2):
|
||||
print(enemy_1)
|
||||
else:
|
||||
print(enemy_2)
|
Reference in New Issue
Block a user