Skip to content

Commit

Permalink
Implement Chris' new savings policy
Browse files Browse the repository at this point in the history
Fixes #557.
  • Loading branch information
jchristgit committed Feb 3, 2025
1 parent 41752d8 commit 4e0b6f9
Showing 1 changed file with 23 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,29 @@ accrued_interest = 0
for _ in range(days_griefed):
accrued_interest += interest_per_day * (savings + accrued_interest)

savings_policy_v1_start = datetime.date(2025, 3, 1)
savings_policy_v1_standard_savings_per_month = 50
savings_policy_v1_savings_per_month = {
# Roses are red,
# violets are blue,
# running heat pumps in winter
# makes Chris Lovering poor
12: savings_policy_v1_standard_savings_per_month - 10,
1: savings_policy_v1_standard_savings_per_month - 20,
2: savings_policy_v1_standard_savings_per_month - 10,
}
savings_policy_cursor = datetime.date(2025, 3, 1)
while savings_policy_cursor <= today:
# Chris thinks about saving every day, but he only manages to actually put
# money into his bank account on the 1st of every month due to a "tax
# advisor suggestion".
if savings_policy_cursor.day == 1:
savings += savings_policy_v1_savings_per_month.get(
savings_policy_cursor.month,
savings_policy_v1_standard_savings_per_month
)
savings_policy_cursor += datetime.timedelta(days=1)

inherited_money = 0

if days_griefed > 10:
Expand Down

0 comments on commit 4e0b6f9

Please sign in to comment.