When we run the following code, all values of each row will be printed
df.apply(lambdax:print(x), axis=1)
total_bill 16.99
tip 1.01
sex Female
smoker No
day Sun
time Dinner
size 2
Name: 0, dtype: object
total_bill 10.34
tip 1.66
sex Male
smoker No
day Sun
time Dinner
size 3
Name: 1, dtype: object
...
Following are different ways to use apply function to create new columns in a data frame