Write a complete C++ program, to determine whether or not a person is eligible for Malaysian Family Assistance. The program should be able to do the following tasks: Task 1: Write a "getInput" function. a) This is a function that does not return any values. b) It accepts as input parameters the identity card (IC) number, gross monthly income, eligibility status, and number of children. c) The function should prompt the user to enter their IC number, gross monthly income, and the number of children they have if they are eligible. A person is eligible for this assistance if their gross monthly income does not exceed RM5000. d) The function returns to the calling module all of the values entered by the user in (c), as well as the eligibility status using reference parameters. Task 2: Write a "deterAmountAssist" function.  a) It accepts as input parameters the gross monthly income and the number of children. b) The function should determine the amount of assistance received by those who are eligible based on the criteria listed in Table 1. c) It should return the value determined in (b). Table 1 Gross monthly income (RM) Number of children 0 1 – 2 ≥ 3 2,500 and below RM1,000 RM1,500 RM2,000 2,501 – 5,000 RM400 RM600 RM800   Task 3: Write a main function.  a) You need to use an appropriate LOOP to perform the process in this function. The loop will be repeated when the user press ‘Y’ or ‘y’. b) You are NOT ALLOWED to use arrays except an array of characters. c) The function may need to call the functions defined in Task 1 and Task 2. d) The program should generate the output shown in the sample execution below. The values in bold are those entered by the user. Task 4: You must ensure that your program meet the following criteria: (5 marks) a) The program can be executed. b) The program employs an appropriate structure for the program (e.g. all required header files are included, the program is properly written, proper indentation, etc.)     SAMPLE PROGRAM EXECUTION << Check eligibility for Malaysian Family Assistance >> IC number: 720322015617 Gross monthly income: RM6543.23 Status: NOT ELIGIBLE Press 'Y' to enter other data: y

Computer Networking: A Top-Down Approach (7th Edition)
7th Edition
ISBN:9780133594140
Author:James Kurose, Keith Ross
Publisher:James Kurose, Keith Ross
Chapter1: Computer Networks And The Internet
Section: Chapter Questions
Problem R1RQ: What is the difference between a host and an end system? List several different types of end...
icon
Related questions
Question

 Write a complete C++ program, to determine whether or not a person is eligible for Malaysian
Family Assistance. The program should be able to do the following tasks:

Task 1: Write a "getInput" function.
a) This is a function that does not return any values.
b) It accepts as input parameters the identity card (IC) number, gross monthly
income, eligibility status, and number of children.
c) The function should prompt the user to enter their IC number, gross monthly
income, and the number of children they have if they are eligible. A person is
eligible for this assistance if their gross monthly income does not exceed
RM5000.
d) The function returns to the calling module all of the values entered by the user in
(c), as well as the eligibility status using reference parameters.

Task 2: Write a "deterAmountAssist" function. 
a) It accepts as input parameters the gross monthly income and the number of
children.
b) The function should determine the amount of assistance received by those who
are eligible based on the criteria listed in Table 1.
c) It should return the value determined in (b).
Table 1

Gross monthly
income (RM)
Number of children
0 1 – 2 ≥ 3
2,500 and below RM1,000 RM1,500 RM2,000
2,501 – 5,000 RM400 RM600 RM800

 

Task 3: Write a main function. 
a) You need to use an appropriate LOOP to perform the process in this function.
The loop will be repeated when the user press ‘Y’ or ‘y’.
b) You are NOT ALLOWED to use arrays except an array of characters.
c) The function may need to call the functions defined in Task 1 and Task 2.
d) The program should generate the output shown in the sample execution below.
The values in bold are those entered by the user.
Task 4: You must ensure that your program meet the following criteria: (5 marks)
a) The program can be executed.
b) The program employs an appropriate structure for the program (e.g. all required
header files are included, the program is properly written, proper indentation, etc.) 

 

 SAMPLE PROGRAM EXECUTION
<< Check eligibility for Malaysian Family Assistance >>
IC number: 720322015617
Gross monthly income: RM6543.23
Status: NOT ELIGIBLE
Press 'Y' to enter other data: y 

Expert Solution
steps

Step by step

Solved in 2 steps with 2 images

Blurred answer
Recommended textbooks for you
Computer Networking: A Top-Down Approach (7th Edi…
Computer Networking: A Top-Down Approach (7th Edi…
Computer Engineering
ISBN:
9780133594140
Author:
James Kurose, Keith Ross
Publisher:
PEARSON
Computer Organization and Design MIPS Edition, Fi…
Computer Organization and Design MIPS Edition, Fi…
Computer Engineering
ISBN:
9780124077263
Author:
David A. Patterson, John L. Hennessy
Publisher:
Elsevier Science
Network+ Guide to Networks (MindTap Course List)
Network+ Guide to Networks (MindTap Course List)
Computer Engineering
ISBN:
9781337569330
Author:
Jill West, Tamara Dean, Jean Andrews
Publisher:
Cengage Learning
Concepts of Database Management
Concepts of Database Management
Computer Engineering
ISBN:
9781337093422
Author:
Joy L. Starks, Philip J. Pratt, Mary Z. Last
Publisher:
Cengage Learning
Prelude to Programming
Prelude to Programming
Computer Engineering
ISBN:
9780133750423
Author:
VENIT, Stewart
Publisher:
Pearson Education
Sc Business Data Communications and Networking, T…
Sc Business Data Communications and Networking, T…
Computer Engineering
ISBN:
9781119368830
Author:
FITZGERALD
Publisher:
WILEY