Question No.7: A formatted file master.txt contains the employee code, name and basic pay of employees of an organization. Write a program to calculate the D.A(dearness allowance), H.R.A (House rent allowance) and gross income of each employee and store employee code, name, basic pay, D.AHR.A and gross income to the file emp.txt, where D.A is the 32% of basic pay, H.R.A is 15% of basic pay and gross pay is the sum of basic pay, D.A and H.R.A.

C++ for Engineers and Scientists
4th Edition
ISBN:9781133187844
Author:Bronson, Gary J.
Publisher:Bronson, Gary J.
Chapter8: I/o Streams And Data Files
Section8.5: A Case Study: Pollen Count File Update
Problem 3E
icon
Related questions
Topic Video
Question

Write a C program and format use in the program (Printf & Scanf)

Question No.7:
A formatted file master.txt contains the employee code, name and basic pay of employees of an
organization. Write a program to calculate the D.A(dearness allowance), H.R.A (House rent allowance)
and gross income of each employee and store employee code, name, basic pay, D.A.H.R.A and gross
income to the file emp.txt, where D.A is the 32% of basic pay, H.R.A is 15% of basic pay and gross pay
is the sum of basic pay, D.A and H.R.A.
Transcribed Image Text:Question No.7: A formatted file master.txt contains the employee code, name and basic pay of employees of an organization. Write a program to calculate the D.A(dearness allowance), H.R.A (House rent allowance) and gross income of each employee and store employee code, name, basic pay, D.A.H.R.A and gross income to the file emp.txt, where D.A is the 32% of basic pay, H.R.A is 15% of basic pay and gross pay is the sum of basic pay, D.A and H.R.A.
Expert Solution
steps

Step by step

Solved in 4 steps with 3 images

Blurred answer
Knowledge Booster
Instruction Format
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
  • SEE MORE QUESTIONS
Recommended textbooks for you
C++ for Engineers and Scientists
C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning