write a program to assign basic salary of employee basic pay. Calculate DA =90 % of basic salary , HRA =30% of basic salary and total salary = basicPay +DA+HRA, print all the data as output
Answers
Answered by
3
Answer:
import java.util.*;
Class employee
{
public static void main (string args[])
{
Scanner sc = new Scanner ( System.in);
System.out.println("Enter the name of the employee");
string nm = in.next();
System.out.println ("Enter the basic salary")
int sal = in.nextInt();
{
double da , hra ,pf, gp =0.00, np=0.00;
da = 0.30*sal;
hra=12.5*sal;
pf=0.10*sal;
gp = sal+ da+hra;
np = gp - pf;
}
System.out.println(" Name of the employee :"+nm);
System.out.println("Basic salary : "+sal);
System.out.println("Gross salary :"+ gp);
System.out.println(" Net salary "+np);
}}
WRITTEN IN JAVA,BLUEJ.
LIKE MY ANSWER
FOLLOW ME
MARK ME AS BRAINLIEST
HOPE IT HELPS
Similar questions