Skip to content

Instantly share code, notes, and snippets.

@itcrab
Created September 13, 2023 08:40
Show Gist options
  • Select an option

  • Save itcrab/eb8dea80a2dd83c9a414322edf762ca5 to your computer and use it in GitHub Desktop.

Select an option

Save itcrab/eb8dea80a2dd83c9a414322edf762ca5 to your computer and use it in GitHub Desktop.
day_flow = lambda *actions: print('\n'.join(actions))
year_days = 365.25
max_days = 65 * year_days
cur_days = 0
i_am_developer = lambda: cur_days <= max_days
while i_am_developer():
day_flow('sleep', 'eat', 'develop', 'eat', 'develop', 'eat', 'family', 'develop')
cur_days += 1
cur_years = int(cur_days // year_days)
print(f'Years: {cur_years}, Day: {cur_days}')
print('====================================')
if cur_days >= max_days:
try:
days_plus = int(input('Do you want continue developing? Enter days count: '))
except ValueError:
break
if days_plus:
max_days += days_plus
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment