Computer Science, asked by anshikay019, 3 months ago

Write a program in java ,Accept the salary of an employee from the user. Calculate and print the gross salary on the following basis:
BASIC HRA DA
1 – 4000 10% 50%
4001 – 8000 20% 60%
8001 - 12000 25% 70%
12000 and above 30% 80%

Answers

Answered by ramchandrashinde75
0

Explanation:

GEEKSFORGEEKS

Program to calculate gross salary of a person

Given an integer basic and a character grade which denotes the basic salary and grade of a person respectively, the task is to find the gross salary of the person.

Gross Salary: The final salary computed after the additions of DA, HRA and other allowances. The formula for Gross Salary is defined as below:

Gross Salary = Basic + HRA + DA + Allow – PF

Here, HRA = 20% of Basic

DA = 50% of basic

Allow = 1700 if grade = ‘A’

Allow = 1500 if grade = ‘B’

Allow = 1300 if grade = ‘C’

PF = 11% of basic

Similar questions