Jasmunn & Jude Pools INC.
Hello!
REPEAT
Ask width between 2 meters to 10 meters
input width
if (width<2) or (width >10)
incorrect value
until ((width >=2) and (width <=10))
repeat
ask length between 10 to 15 meters
input length
if (length<width or length>15)
incorrect value
until ((length >=width) and (length <=15))
repeat
ask depth between 3 to 6 meters
Input Depth
if (depth <3 or depth > 6)
incorrect value
until ((depth >=3) or depth <=6)
// calculate Sidewalk
Perimeter=(2L+2W)
SidewalkCost = perimeter x 250
// Calculate Pool
Volume(LxWxDepth)
PoolCost = Volume x 100
// Calculate Total cost including Tax.
Subtotal = SidewalkCost + PoolCost
GST = Subtotal x 0.05
PST = Subtotal x 0.07
Total = Subtotal + GST + PST
Display Bill
//Ask User to calculate another Pool
1 = Yes
2 = No
Neither Input entered
Invalid
Repeat until prompt selected
1 = Repeat Calculation
if else; end program
//goodbye
Hello!
REPEAT
Ask width between 2 meters to 10 meters
input width
if (width<2) or (width >10)
incorrect value
until ((width >=2) and (width <=10))
repeat
ask length between 10 to 15 meters
input length
if (length<width or length>15)
incorrect value
until ((length >=width) and (length <=15))
repeat
ask depth between 3 to 6 meters
Input Depth
if (depth <3 or depth > 6)
incorrect value
until ((depth >=3) or depth <=6)
// calculate Sidewalk
Perimeter=(2L+2W)
SidewalkCost = perimeter x 250
// Calculate Pool
Volume(LxWxDepth)
PoolCost = Volume x 100
// Calculate Total cost including Tax.
Subtotal = SidewalkCost + PoolCost
GST = Subtotal x 0.05
PST = Subtotal x 0.07
Total = Subtotal + GST + PST
Display Bill
//Ask User to calculate another Pool
1 = Yes
2 = No
Neither Input entered
Invalid
Repeat until prompt selected
1 = Repeat Calculation
if else; end program
//goodbye