• Determine the goal and the items that are needed to achieve that goal.
• Design solution using Step from Algorithm and Flowchart, Desk check your algorithm
• Implementation using Java, Debug and execute
The owner of the ‘Lunch Café’ aims to sell daily a reasonably-priced three-course lunch to the local student community. To save costs, each day there is only a single choice of starter, main course and dessert. As with most establishments of its kind, the largest profit comes from selling the main courses. Unfortunately, the local students being frugal, hard-working and cost-conscious tend to only order a starter and/or a dessert.
As an incentive to order main courses, the owner has decided – where customers order a main course – to provide, free of charge:
• a soft drink if they also order a starter;
• coffee if they also order a dessert;
• both a soft drink and a coffee if all 3 courses are ordered.
If customers do not order a main course or if they only order a main course, then there are no drinks provided.
You are to write a program that advises staff what to provide. The program should ask what course(s) the customer is ordering and output what is to be provided. The choices are:
• starter at RM3
• main course at RM6
• dessert at RM4
• soft drink at RM1.5 (free only if both a starter & a main course have been ordered)
• coffee at RM2 (free only of both a dessert & a main course have been ordered)
Tasks to do
1. Design solution using Step form Algorithm / flow chart. (10 marks)
2. Desk check your algorithm with reasonable inputs (10 marks)
3. Implementation using Java (30 marks)
4. Debug and execute.