A bank app stores your payments as a list of dictionaries. Each payment has a "category" and an "amount".
"category"
"amount"
Write category_totals(payments) that returns a dictionary of each category to the total amount spent in it.
category_totals(payments)
1def category_totals(payments):2 # your code here3 pass4