TypeError Traceback (most recent call last)
Cell In[1], line 16
13 personal_income_tax_threshold = 5000
15 # 计算社保缴费总额
—> 16 total_social_security = sum([base * rate for base, rate in social_security_rates.items()])
18 # 计算应纳税所得额
19 taxable_income = 4800 - total_social_security - personal_income_tax_threshold
Cell In[1], line 16, in <listcomp>(.0)
13 personal_income_tax_threshold = 5000
15 # 计算社保缴费总额
—> 16 total_social_security = sum([base * rate for base, rate in social_security_rates.items()])
18 # 计算应纳税所得额
19 taxable_income = 4800 - total_social_security - personal_income_tax_threshold
TypeError: can’t multiply sequence by non-int of type ‘float’