Update value of pandas dataframe column with leading zero where the length of the value is equal to 2 I have an example pandas data frame (df) with the following values: