I'm new to programming and I'd like to know how one would approach a solution to the problem:
A python script that reads two excel files
- Excel1.xlsx (has only 1 column)
- Excel2.xlsx (has only 1 column)
Then the script would get the names of each excel file and create a NEW EXCEL FILE with the names of Excel1.xlsx that ARE NOT IN Excel2.xlsx
Example :
Excel1 has {"Bob , Bill , Joe, Sam, Frank"}
Excel2 has {"Bob, Joe, Sam, Frank"}
Expected output would be:
NewExcelFile {"Bill"}
Since I'm new I know how to read files but I don't know how I'd go from here:
import pandas as pd
Excel1 = pd.read_excel(Excel1.xlsx)
Excel2 = pd.read_excel(Excel2.xlsx)
set1 = set(Excel1), set2(Excel2)), and use the set difference to get items from Excel1 not in Excel2:unique = set1 - set2.