The management of a super store needs Customer Management System for registering customers based on some criteria. The system should allow registration management members to perform the following actions: Add customer record (id, name, age, gender and city) to the file. Print customer details (id, name, age, gender and city) Note: The purpose of this Project is to practice file input/output operations in c. Therefore, whenever you add a new customer record, you will be saving ALL the customer information into file. For example, each customer record will have an ID, a first name, a last name, age, gender and city. Project Details: The program will first ask the user to enter the customer registration year and number of customers in the year as shown in below sample: Welcome to the Customer Management System > Please enter the customer registration year (ex: 2017): 2021 > How many customers do you want to register in year 2021: 2 After the user enters the registration year and number of customers, the program should display the following main menu: Customer Management System * MAIN MENU* | A/a: Enter A or a for Adding a customer | D/d: Enter D or d for Printing customer Details | E/e: Enter E or e for Exiting the Program > Please enter your choice: If the user chooses A or a, then the program allows the user to enter the following information: customerID, first name, last name, age, gender, city. o Again, all information is to be stored in an file. • If the user chooses D or d, the program allows the user to print the customers details from file (read the array from file and display on the screen) If the user chooses E or e, the program stop and display the message: > Thank you for using the Customer Management System!

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

please , i need the code for this assignment in C language 

 

> Good Bye.
Input validation
If the user enters incorrect choice for any menu, the program should continue to show the menu
and display the message "Invalid selection! Please try again".
If the user enters the age which is not in the range (15-90), the program should display the error
message "Invalid input! (age must be between 15 and 90)" and enforce the user to enter the
correct age.
If the user enters the gender other than "male or female", the program should display the error
message "Invalid input! (gender must be male or female)" and enforce the user to enter the correct
gender.
Methods:
You MUST use the following methods in your program:
Method name
Function
displayMainMenu
Displaying the main menu
Allows the user to enter (A, a, D, d, E or e) and returns the correct
character. If the user inputs a character that is not recognized (NOT
from A, a, D, d, E or e), then the method should print the message
">Invalid selection! Please try again.", and it enforces the user to
enter the correct character.
inputAndCheck
Allows the user to enter the age and returns it if the entered value is
between 15 and 90 inclusively. Otherwise, the method should print
the message ">Invalid input! (age must be between 15 and 90)" and
other messages "See the sample output" , and it enforces the user to
enter the correct age.
readCustomerAge
Allows the user to enter the customer gender and returns the
customer gender value.
readCustomerGender
Allows the user to enter the customer city and returns the customer
city name.
readCustomerCity
displayCustomerlnformation
Displays the customer details (See sample output)
Transcribed Image Text:> Good Bye. Input validation If the user enters incorrect choice for any menu, the program should continue to show the menu and display the message "Invalid selection! Please try again". If the user enters the age which is not in the range (15-90), the program should display the error message "Invalid input! (age must be between 15 and 90)" and enforce the user to enter the correct age. If the user enters the gender other than "male or female", the program should display the error message "Invalid input! (gender must be male or female)" and enforce the user to enter the correct gender. Methods: You MUST use the following methods in your program: Method name Function displayMainMenu Displaying the main menu Allows the user to enter (A, a, D, d, E or e) and returns the correct character. If the user inputs a character that is not recognized (NOT from A, a, D, d, E or e), then the method should print the message ">Invalid selection! Please try again.", and it enforces the user to enter the correct character. inputAndCheck Allows the user to enter the age and returns it if the entered value is between 15 and 90 inclusively. Otherwise, the method should print the message ">Invalid input! (age must be between 15 and 90)" and other messages "See the sample output" , and it enforces the user to enter the correct age. readCustomerAge Allows the user to enter the customer gender and returns the customer gender value. readCustomerGender Allows the user to enter the customer city and returns the customer city name. readCustomerCity displayCustomerlnformation Displays the customer details (See sample output)
Project Description:
The management of a super store needs Customer Management System for registering customers
based on some criteria. The system should allow registration management members to perform the
following actions:
Add customer record (id, name, age, gender and city) to the file.
Print customer details (id, name, age, gender and city)
Note: The purpose of this Project is to practice file input/output operations in c. Therefore, whenever
you add a new customer record, you will be saving ALL the customer information into file. For
example, each customer record will have an ID, a first name, a last name, age, gender and city.
Project Details:
The program will first ask the user to enter the customer registration year and number of customers in
the year as shown in below sample:
Welcome to the Customer Management System
> Please enter the customer registration year (ex: 2017): 2021
> How many customers do you want to register in year 2021: 2
After the user enters the registration year and number of customers, the program should display the
following main menu:
Customer Management System
* MAIN MENU*
| A/a: Enter A or a for Adding a customer
| D/d: Enter D or d for Printing customer Details
| E/e: Enter E or e for Exiting the Program
> Please enter your choice:
If the user chooses A or a, then the program allows the user to enter the following information:
customerID, first name, last name, age, gender, city.
o Again, all information is to be stored in an file.
• If the user chooses D or d, the program allows the user to print the customers details from file
(read the array from file and display on the screen)
. If the user chooses E or e, the program stop and display the message:
> Thank you for using the Customer Management System!
Transcribed Image Text:Project Description: The management of a super store needs Customer Management System for registering customers based on some criteria. The system should allow registration management members to perform the following actions: Add customer record (id, name, age, gender and city) to the file. Print customer details (id, name, age, gender and city) Note: The purpose of this Project is to practice file input/output operations in c. Therefore, whenever you add a new customer record, you will be saving ALL the customer information into file. For example, each customer record will have an ID, a first name, a last name, age, gender and city. Project Details: The program will first ask the user to enter the customer registration year and number of customers in the year as shown in below sample: Welcome to the Customer Management System > Please enter the customer registration year (ex: 2017): 2021 > How many customers do you want to register in year 2021: 2 After the user enters the registration year and number of customers, the program should display the following main menu: Customer Management System * MAIN MENU* | A/a: Enter A or a for Adding a customer | D/d: Enter D or d for Printing customer Details | E/e: Enter E or e for Exiting the Program > Please enter your choice: If the user chooses A or a, then the program allows the user to enter the following information: customerID, first name, last name, age, gender, city. o Again, all information is to be stored in an file. • If the user chooses D or d, the program allows the user to print the customers details from file (read the array from file and display on the screen) . If the user chooses E or e, the program stop and display the message: > Thank you for using the Customer Management System!
Expert Solution
steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Knowledge Booster
Fundamentals of Boolean Algebra and Digital Logics
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education