Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

really stuck on this question. need the flowchart done for it and then put into c program and then to an output. would be much

really stuck on this question. need the flowchart done for it and then put into c program and then to an output. would be much appreciated. thank you

image text in transcribedimage text in transcribedimage text in transcribedimage text in transcribed

Qn1. 20 Marks A leading Australian bank is maintaining its customer details based on the following database table structure. Customer Customer_ID Name Count of Accounts Ex: 1001 Amber 1 Ex: 1002 Aiden 2 Accounts Account_ID Ex: A101 Ex: A102 Ex: A103 Customer_ID Account_Type Balance 1001 Savings 1200 1002 Savings 1000 1002 Cheque 800 The bank has approached you to develop a simple menu drive program to read and manage customers and account details. The bank has made the following requirements: a. The program should be menu-driven b. A customer could maintain zero (0) or more accounts c. Each account to be linked to a customer d. The types of accounts are Savings. Cheque, Credit, and Transaction e. Except for Savings, all other accounts can have negative balances f. Your program should be capable of creating and storing any number of customers with zero to four accounts for each customer g Your program should have the facility to search customer by customer name h. Your program should have the facility to calculate the total balance across all the accounts for a customer i. Your program should have the facility to calculate the total balances across all the accounts j. The program should have the facility to display all customers and account details As part of this assessment, you are required to develop a C-language-based program to fulfil the above requirements. Your program should be based on the following instructions: a. Use appropriate C-language constructs to create customer records - Structures b. Use appropriate C-language constructs to create account records - Nested Structures C. Ensure your approach allows a customer to maintain 0 or many accounts d. Use enum to create account types e. Use dynamic memory allocation to create and maintain any number of customers and accounts. f. Total balance calculation should be done using Recursive Function The main menu of your program should be: 1. Add new customer 2. Display all customer 3. Search customer by name 4. Calculate total balances for a customer 5. Calculate total balances 6. Exit Enter your choice--1 On selection of option:1, the following details to be collected a. Enter the customer details: b. Customer Name: C. Customer ID: d. How may accounts for the customer Based on the input to option d, the program should read policy details a. Enter account ID b. Enter account type C. Enter balance On selection of option two in the main menu: 1. Add new customer 2. Display all customers 3. Search customer by name 4. Calculate total balances for a customer 5. Calculate total balances 6. Exit Enter your choice--2 On selection of option 2, the program to display all the customers details and details of each account/s held by the customer. The output to be in the following format Customer Name: Amber Customer ID: 1001 Account ID: A101 Type: Savings Balance: 1200 Customer Name: Aiden Customer ID: 1002 Account ID: A102 Type: Savings Balance: 1000 Account ID: A103 Type: Cheque Balance: 800 On selection of option 3 in the main menu: 1. Add new customer 2. Display all customer 3. Search customer by name 4. Calculate total balances for a customer 5. Calculate total balances 6. Exit Enter your choice---3 On selection of option 3 from the main menu, the program to display the following options: Enter the name of the customer: Amber Details for Amber: Customer ID: 1001 Number of Accounts: 1 Account ID: 101 Type: Savings Balance: 1200 Enter the name of the customer: Helen Sorry, no details for Helen found. On selection of option 4 in the main menu: 1. Add new member 2. Display all members 3. Search member by name 4. Calculate total balances for a customer 5. Calculate total premium 6. Exit On selection of option 4 from the main menu, the program to display the total balances of all the accounts held by the customer. The total premium calculation should be implemented using Recursive Function. Enter the name of the customer: Amber Total balance: 1200 Enter the name of the customer: Aiden Total balance: 1800 On selection of option 5 in the main menu: 1. Add new member 2. Display all members 3. Search member by name 4. Calculate total balances for a customer 5. Calculate total premium 6. Exit On selection of option 5 from the main menu, the program to display the total balances of all the accounts. The total premium calculation should be implemented using Recursive Function, Total balance: 3000 On selection of option 6 in the main menu: 1. Add new member 2. Display all members 3. Search member by name 4. Calculate total balances for a customer 5. Calculate total premium 6. Exit

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Introduction To Database And Knowledge Base Systems

Authors: S Krishna

1st Edition

9810206208, 978-9810206208

More Books

Students also viewed these Databases questions