Got the loop to work properly for multiple expression in a row