Question: Write a function, called congress_session_members, that takes a congress session # session_number (int) and a file_name (str). It should load the data created in question
Write a function, called congress_session_members, that takes a congress session # session_number (int) and a file_name (str). It should load the data created in question 6 # and search for all the senators that were part of that particular session of congress. # The function should write the resulting senators to a file called # congress_session{session_number}.json and returns a list of every senator that was # part of the Senate for the given session_number. It should return an empty # list if none of the senators were members for that congress. # (Congress session 1 should have nobody in it (except maybe Chuck Grassley # and Mitch McConnell)). # The numbers of senators for each Congress session available. # session_number 116 = 33 # session_number 117 = 64 # session_number 118 = 100 # session_number 119 = 66 # session_number 120 = 34 # all other session numbers should be empty
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
