Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <stdbool.h>
- int main() {
- double admin_fee, course_fee, meal_v_fee, meal_nv_feel;
- char category;
- int course_no;
- bool quit = true;
- printf("\nA. Soft Skills\nB. Computing Skills\n");
- printf("Which category you want to learn for?: ");
- while (quit) {
- scanf("%s", &category);
- switch (category) {
- case'A':
- case'a':
- printf("Category: Software Skills");
- printf("\n____________________________________________________________________________________________________________");
- printf("\n| NO | Course | Day | Admin | Payment Rate (RM) |");
- printf("\n| | | | Fee | Per Day |");
- printf("\n| | | | (RM) |------------------------------------------|");
- printf("\n| | | | | Fee | Meal | Meal |");
- printf("\n| | | | | | (vegetarian) | (non-vegetarian) |");
- printf("\n|----|--------------------------|-------------|-----------------|------------------------------------------|");
- printf("\n| 1 | Team Building | 3 | 50 | 800 | 75 | 50 |");
- printf("\n|----|--------------------------|-------------|-----------------|-------|--------------|-------------------|");
- printf("\n| 2 | Communications | 3 | 50 | 650 | 50 | 25 |");
- printf("\n|----|--------------------------|-------------|-----------------|-------|--------------|-------------------|");
- printf("\n| 3 | Corporate Career | 3 | 50 | 750 | 50 | 25 |");
- printf("\n| | Growth | | | | | |");
- printf("\n|----|--------------------------|-------------|-----------------|-------|--------------|-------------------|");
- printf("\n| 4 | Conflict Management | 3 | 50 | 600 | 50 | 25 |");
- printf("\n|____|__________________________|_____________|_________________|_______|______________|___________________|");
- printf("\nWhat course you want to book? Input Q to return");
- break;
- case'B':
- case'b':
- printf("Category: Computing Skills");
- printf("\n____________________________________________________________________________________________________________");
- printf("\n| NO | Course | Day | Admin | Payment Rate (RM) |");
- printf("\n| | | | Fee | Per Day |");
- printf("\n| | | | (RM) |------------------------------------------|");
- printf("\n| | | | | Fee | Meal | Meal |");
- printf("\n| | | | | | (vegetarian) | (non-vegetarian) |");
- printf("\n|----|--------------------------|-------------|-----------------|------------------------------------------|");
- printf("\n| 1 | Software Design | 5 | 50 | 1000 | 50 | 25 |");
- printf("\n|----|--------------------------|-------------|-----------------|-------|--------------|-------------------|");
- printf("\n| 2 | Web Development | 5 | 50 | 1100 | 75 | 50 |");
- printf("\n|----|--------------------------|-------------|-----------------|-------|--------------|-------------------|");
- printf("\n| 3 | Cloud Computing | 3 | 50 | 1300 | 50 | 25 |");
- printf("\n|----|--------------------------|-------------|-----------------|-------|--------------|-------------------|");
- printf("\n| 4 | Mobile Content | | | | | |");
- printf("\n| | Design and | 5 | 50 | 1200 | 75 | 50 |");
- printf("\n| | Developmen | | | | | |");
- printf("\n|____|__________________________|_____________|_________________|_______|______________|___________________|");
- printf("\nWhat do you want to book? ");
- scanf("%d", &course_no);
- break;
- default:
- printf("Invalid Input! PLease input again: ");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement