Soal Case her-shey bar her-shey bar is a famous chocolate shop in Indonesia that has order from every location worldwide

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899603
Joined: Mon Aug 02, 2021 8:13 am

Soal Case her-shey bar her-shey bar is a famous chocolate shop in Indonesia that has order from every location worldwide

Post by answerhappygod »

Soal Case Her Shey Bar Her Shey Bar Is A Famous Chocolate Shop In Indonesia That Has Order From Every Location Worldwide 1
Soal Case Her Shey Bar Her Shey Bar Is A Famous Chocolate Shop In Indonesia That Has Order From Every Location Worldwide 1 (66.06 KiB) Viewed 21 times
Soal Case Her Shey Bar Her Shey Bar Is A Famous Chocolate Shop In Indonesia That Has Order From Every Location Worldwide 2
Soal Case Her Shey Bar Her Shey Bar Is A Famous Chocolate Shop In Indonesia That Has Order From Every Location Worldwide 2 (50.8 KiB) Viewed 21 times
Soal Case Her Shey Bar Her Shey Bar Is A Famous Chocolate Shop In Indonesia That Has Order From Every Location Worldwide 3
Soal Case Her Shey Bar Her Shey Bar Is A Famous Chocolate Shop In Indonesia That Has Order From Every Location Worldwide 3 (109.47 KiB) Viewed 21 times
Soal Case Her Shey Bar Her Shey Bar Is A Famous Chocolate Shop In Indonesia That Has Order From Every Location Worldwide 4
Soal Case Her Shey Bar Her Shey Bar Is A Famous Chocolate Shop In Indonesia That Has Order From Every Location Worldwide 4 (167.77 KiB) Viewed 21 times
Soal Case Her Shey Bar Her Shey Bar Is A Famous Chocolate Shop In Indonesia That Has Order From Every Location Worldwide 5
Soal Case Her Shey Bar Her Shey Bar Is A Famous Chocolate Shop In Indonesia That Has Order From Every Location Worldwide 5 (131.59 KiB) Viewed 21 times
Soal Case Her Shey Bar Her Shey Bar Is A Famous Chocolate Shop In Indonesia That Has Order From Every Location Worldwide 6
Soal Case Her Shey Bar Her Shey Bar Is A Famous Chocolate Shop In Indonesia That Has Order From Every Location Worldwide 6 (118.32 KiB) Viewed 21 times
Someone please help and do in C
Soal Case her-shey bar her-shey bar is a famous chocolate shop in Indonesia that has order from every location worldwide. In the past, manually tracking the data of each chocolate they produce is still manageable. Now, given tons of chocolate are being produced everyday, the CEO of her-shey bar, Mr. James hired you to create an application which uses AVL Tree as its base algorithm for fast data management. You are to create an application based on the following requirements: • At the start of the program, there will be 4 menus, which consists of: Add Chocolate View all Chocolate Remove Chocolate Exit . .
her-shey bar (_/\_)() 1. Add Chocolate 2. View all Chocolates 3. Remove Chocolate 4. Exit Choose >> Figure 1. main menu
If user choose menu 1 (Add Chocolate), the program will : Prompt user to input Chocolate Brand. Validate the input based on following conditions: > Input must be between 3 and 30 characters (inclusive) ➤ Input must be in capital format and consist of alphabets and spaces only Prompt user to input Chocolate Weight. Validate the input must be more than 20 and multiple of 5 Prompt user to input Chocolate Type. Validate the input must be between "White", "Milk", "Dark", "Cocoa", and "Ruby" (case sensitive) Prompt user to input Chocolate Price. Validate the input must be between 1.0 and 5000.0 (inclusive) Prompt user to input Confirmation Input. Validate the input must be between "Y" and "N" (case sensitive) If Confirmation Input is "Y", > Generate Chocolate ID based on following formula: . . . . . . XXX-YY-ZZZZ XXX: First 3 characters of Chocolate Type in uppercase YY: First 2 characters of Chocolate Brand in uppercase ZZZZ: Last Chocolate ID count incremented by 1 ➤ Finally, create a node with all data and push unto AVL Tree with Chocolate ID as its key
Input chocolate brand [3 - 30 characters]: da Input chocolate brand [3] 30 characters]: Dairy Queen Input chocolate weight [> 20, multiple of 5]: 15 Input chocolate weight [> 20, multiple of 5]: 35 Input chocolate type [White | Milk | Dark | Cocoa | Ruby]: milk Input chocolate type [White | Milk | Dark | Cocoa | Ruby]: Cocoa Input chocolate price [$1.0 - $5000.0]: 0 Input chocolate price [$1.0 - $5000.0]: 4.9 Are you sure want to add? [Y | N]: y Are you sure want to add? [Y | N]: Y Chocolate with ID COC-DA-0004 added succesfully :D Press enter to continue... . Figure 2. insert chocolate data Otherwise, redirect to main menu If user choose menu 2 (View all Chocolate), the program will : . Check data from AVL Tree. If there are no data, display following message There are no Chocolate yet! Press enter to continue... . Figure 3. no data message Otherwise, > Prompt user to input View Input. Validate the input must be between "Pre", "In", and "Post" (case sensitive) Choose Order [Pre | In | Post]: Figure 4. view input prompt ➤ If View Input is "Pre", display all data in pre-order format
ID | Brand | Reese's | Snickers | Dairy Queen MIL-RE-0003 DAR-SN-0002 COC-DA-0004 WHI-KI-0001 | Kit Kat Press enter to continue... ID | Brand COC-DA-0004 | Dairy Queen DAR-SN-0002 | Snickers MIL-RE-0003 | Reese's WHI-KI-0001 | Kit Kat Figure 5. view data in pre-order format If View Input is "In", display all data in in-order format Press enter to continue... | Weight | Type | 135 g | Milk | 200 g| Dark | 35 | 25 | Price | $11.5 | $9.9 g Cocoa | $4.9 g | White | $5.4 | Weight | Type | Price | 35 g Cocoa | $4.9 | 200 g | Dark | $9.9 | $11.5 | $5.4 | 135 | 25 g Milk g White I Figure 6. view data in in-order format ➤ If View Input is "Post", display all data in post-order format
Input ID to remove [0 to return to main menu]: A Input ID to remove [0 to return to main menu]: Figure 10. searched data not exists Otherwise, ❖ Prompt user to input Confirmation Input. Validate the input must be between "Y" and "N" (case sensitive) Input ID to remove [0 to return to main menu]: MIL-RE-0003 Are you sure want to remove chocolate MIL-RE-0003? [Y | N]: Figure 11. confirmation input prompt If Confirmation Input is "Y", remove data from AVL Tree and display following message Input ID to remove [0 to return to main menu]: MIL-RE-0003 Are you sure want to remove chocolate MIL-RE-0003? [Y | N]: Y Chocolate with ID MIL-RE-0003 removed! Press enter to continue... Figure 12. successfully delete data message Otherwise, redirect to main menu If user choose menu 4 (Exit), the program will close
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply