1# Subtract 1 from row, for each row in df.year
2df['previous_year'] = [row-1 for row in df['year']]
1df['Flag'] = ["High Bracket" if x > 70 else "Low Bracket" for x in df['prevsalary']]
2
1df['Flag2'] = ["Increase" if x > y else "Decrease" for (x,y) in zip(df['nextsalary'],df['prevsalary'])]
2