import pandas as pd
# making data frame from csv file
data = pd.read_csv("employees.csv")
# sorting by first name
data.sort_values("First Name", inplace = True)
# dropping ALL duplicte values
data.drop_duplicates(subset ="First Name",keep = False, inplace = True)
# displaying data
print(data)
data = data.drop_duplicates(subset=['City'], keep='first')
df = df.loc[:,~df.columns.duplicated()]
# Drop duplicate columns
df2 = df.T.drop_duplicates().T
print(df2)
df.drop_duplicates(keep=False, inplace=True)
df.loc[:,~df.columns.duplicated()]
df = df.loc[:,~df.columns.duplicated()].copy()
# https://stackoverflow.com/questions/14984119/python-pandas-remove-duplicate-columns