Compute the Cost of Booking a Workspace
Explore how to calculate the cost of booking different types of workspaces by using conditional statements in programming. Learn to apply IF, ELSE-IF, and ELSE logic to decide costs based on workspace and pass types, while practicing problem-solving, pseudocode, and flowchart creation.
Problem statement
You want to book a workspace to increase your productivity. You have the option to choose from the following: an open office space, a dedicated desk, or a private office. You can also decide if you want a daily pass or a monthly pass for the workspace, and you wish to find out the cost based on your requirement. You have the following information:
Open office space
| Pass Type | Cost |
|---|---|
| Daily | $20 |
| Monthly | $560 |
Dedicated desk
| Pass Type | Cost |
|---|---|
| Daily | $10 |
| Monthly | $270 |
Private office