''' Author: Day 18 Classwork - Problem #2 We want to answer the following question: What is the variation of magnitudes in the recorded earthquakes, in the state of California? To answer the question you must plot the magnitudes of earthquakes stored in the data structure given by get_report, for the given state. The code provided counts the number of earthquakes in that state. Review the code to understand how to check the location of the earthquake, in relation to the state. You may also reuse some of the code for your solution. ''' import matplotlib.pyplot as plt import earthquakes quake_list = earthquakes.get_report("day","all") count = 0 for quake in quake_list["earthquakes"]: # The "in" operation is True when the left string appears # inside the right string if "California" in quake["location_description"]: count = count + 1 print(count)