Question
CURRENT_YEAR = 2023 # The current year, treat as constant # -----------------------------------------+ # The missing functions go here. # -----------------------------------------+ def main(): add_age(video_games.csv, enhanced_video_games.csv) unique_consoles(video_games.csv)
CURRENT_YEAR = 2023 # The current year, treat as constant
# -----------------------------------------+
# The missing functions go here.
# -----------------------------------------+
def main():
add_age("video_games.csv", "enhanced_video_games.csv") unique_consoles("video_games.csv")
# -----------------------------------------+
main() Write a function named add_age that reads a csv file identified by the value of the first parameter ("video_games.csv" in the supplied code) and creates a new file identified by the value of the second parameter ("enhanced_video_games.csv" in the supplied code). In the new file, insert a second column with the label Age in Years that shows how old each video game is. Do the calculation using the CURRENT_YEAR constant that is provided with the starting code. Write a function named unique_consoles that reads a csv file identified by the value of the parameter ("video_games.csv" in the supplied code) and prints a numbered, alphabetically ordered list of the unique consoles that appear in the file. Match the formatting in this sample.
If the unique_consoles function is correct, the first unique console printed will be 1. Nintendo DS.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Heres the code with the missing functions addage and uniqueconsoles implemented according to the giv...Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started