I joined the leaderboard, but since I'm in a EU timezone and only have time to work on them in the evenings I'm expecting my scores to be quite low 😅
Here's my solution for day 1 with Python (explained my thinking behind it here):
Part 1:
input = np.array([input]) output = np.sum(np.floor(input / 3) - 2)
Part 2:
for module in input_array: new_fuel = mod while True: new_fuel = np.floor(new_fuel / 3) - 2 if new_fuel > 0: total_fuel += new_fuel else: break
Are you sure you want to hide this comment? It will become hidden in your post, but will still be visible via the comment's permalink.
Hide child comments as well
Confirm
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
I joined the leaderboard, but since I'm in a EU timezone and only have time to work on them in the evenings I'm expecting my scores to be quite low 😅
Here's my solution for day 1 with Python (explained my thinking behind it here):
Part 1:
Part 2: