Lab #7 - Task 5

Stephan Knotek

Task 5 - do ... while Loop

  1. Create a new PHP file, then copy and paste the code you created in Task 4 into your new file.
  2. Re-write as a do while loop
  3. Change the counter variable value to 12. This one is tricky.

Remember: Do ... while loops always perform the do command. They only perform the while loop if the conditions are met.

(Hint: Be sure to wrap the line you are displaying in paragraph tags, or use a line break or horizontal rule at the end of each line or everything will run together.)

Tax for 12 dollars is 12 x 0.055 = 0.66.