how to delete the last row in a df code example Example: drop last row pandas df.drop(df.tail(n).index,inplace=True) # drop last n rows