diff --git a/compound_interest.py b/compound_interest.py index e5a7cc4..48bced2 100644 --- a/compound_interest.py +++ b/compound_interest.py @@ -28,7 +28,7 @@ def __init__(self, parent, annual_return, months, monthly_deposit=0, initial_amo for m in range(months): temp_result = (temp_result + monthly_deposit) * monthly_return self.result = int(temp_result) - elif initial_amount: # First CompoundResult in a chain + elif initial_amount is not None: # First CompoundResult in a chain self.result = initial_amount else: raise Exception("CompoundResult constructor without a parent and no initial_amount was given!")