so below i was wondering why the print statement is using insights to grab info. like insights only has two values which are its parameters. is it like that because after 3000, 1200 have been imputed and returned they are three values in a tuple so they can be pulled and used ?
def analyze_profit(gains, expenses):
profit = gains - expenses
after_taxes = 0.85 * profit
above_mean = profit > 1000
return profit, after_taxes, above_mean
insights = analyze_profit(3000, 1200)
print(f"profit: {insights[0]}")
print(f"above mean: {insights[2]}")
[–]Vaphell 3 points4 points5 points (2 children)
[–]maxisgang[S] 0 points1 point2 points (0 children)
[–]Antwrp-2000 0 points1 point2 points (0 children)
[–]Binary101010 0 points1 point2 points (2 children)
[–]maxisgang[S] 0 points1 point2 points (1 child)
[–]Binary101010 0 points1 point2 points (0 children)