CS50 Python | Week 6 | File I/O | Problem Set 6 | Scourgify
Scourgify Pset 6 - scourgify The Challenge: The challenge involves cleaning and reformatting data from a CSV file containing student information. The data is initially structured with names and houses in a single column, separated by a comma and space, and enclosed in double quotes. The goal is to split the names into first and last names and create a new CSV file with columns for first name, last name, and house. The program, implemented in a file called scourgify.py, expects two command-line arguments: the name of an existing CSV file to read as input and the name of a new CSV file to write as output. The program uses the csv module, specifically DictReader and DictWriter, to handle the CSV operations. Additionally, the program performs error handling: If the user does not provide exactly two command-line arguments, the program exits with an error message: "Too few command-line arguments." If the specified input file cannot be read, the program exits with an error message: ...