Question

Write a Java program that calculates and prints the monthly pay for an employee. The net...

Write a Java program that calculates and prints the monthly pay for an employee. The net pay is calculated after taking the following deductions:

Withholding Tax 10%

SSS Contribution 2.50%

Medicare 1.30%

PensionPlan PHP 200.00

Homework Answers

Answer #1

Code:

import java.util.Scanner;
class Main
{
        public static void main(String arg[])   
        {
            double gross_sal, witholding_tax, sss_contribution, medicare ,pag_ibig_php = 200, netSalary;
            Scanner sc=new Scanner(System.in);
            System.out.println("Enter Gross salary");
        gross_sal=sc.nextDouble();
        witholding_tax = 0.1*gross_sal;
        sss_contribution = 0.025*gross_sal;
        medicare = 0.013*gross_sal;
            netSalary = gross_sal- witholding_tax - sss_contribution - medicare - pag_ibig_php;
            System.out.println("Net Salary is=" + netSalary);
    }
}

Output:

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
Write a program that takes the income of an employee and calculates the corresponding net income...
Write a program that takes the income of an employee and calculates the corresponding net income and tax portion based on the following information: (in C++) tax = 40%: income > =100,000 $ tax=30%: 80K<=income<100K tax=20%: 60K<=income<80K tax=10%: 40K<=income<60K tax = 0%: income <40 K
Write a Java program that gets a 4x4 array of numbers and that calculates the sum...
Write a Java program that gets a 4x4 array of numbers and that calculates the sum and average of numbers on the main diagonal, ie the diagonal that goes from the left corner down to the right corner. Examples of resulting programs are: Enter a 4x4 matrix row by row: 1 2 3 4 5 6 7 8 9 1 2 3 4 5 6 7 The sum of numbers in the diagonal is: 16 The average of numbers in...
Question 2: write a java program    A Hypermarket makes an offer for its customers according...
Question 2: write a java program    A Hypermarket makes an offer for its customers according to the number of items to be bought as follows: Number of purchased items Discount percentage Less than 25 2.5% 25 – 50 5.0% 51 – 100 6.25% Greater than 100 7.5% The hypermarket also adds 2% city taxes to the purchases after the sale discount. Reads from the user the number of items to be purchased and the item price. Calculates and prints...
A Cable Company has hired you to write a C++ program that calculates the monthly bill...
A Cable Company has hired you to write a C++ program that calculates the monthly bill for their customers. It must meet the following specifications: The program must first greet the customer. The program must then ask for their name, the number of basic channels packages they’re subscribed to, then the number of premium channel packages they’re subscribed to. The bill is calculated as follows: There is a $75 base fee. The first 3 basic channels packages are free, after...
An employer has one employee who earned $3,000 his first month of employment. The employee’s federal...
An employer has one employee who earned $3,000 his first month of employment. The employee’s federal income tax withholding (FITW) is $400, and the employee has voluntary monthly deductions of $125 for health insurance and $25 for union dues. The FICA tax rate for Social Security is 6.2% and the FICA tax rate for Medicare is 1.45%. The employer's FUTA tax rate is 0.6% and the SUTA tax rate is 5.4%. (Note: The limit for FICA Social Security is $128,400...
* Write a Java program that calculates and displays the Fibonacci numbers * First prompt the...
* Write a Java program that calculates and displays the Fibonacci numbers * First prompt the user to input a number, N * Then use a for loop to calculate and display the first N fibonocci numbers * For example, if the user enters 5, the output should be: * 1, 1, 2, 3, 5 * * if the user enters 10, the output should be: * 1, 1, 2, 3, 5, 8, 13, 21, 34, 55
C++ Write a program that calculates and prints the total grade for n assignments as a...
C++ Write a program that calculates and prints the total grade for n assignments as a percentage. Prompt the user to enter the value of n, followed by the number of points received and number of points possible for each assignment . Calculate and print the total number of points received, total number of points possible, and the overall percentage: (total points received / total points possible) * 100. Output: Enter·number·of·assignments·to·input:3↵ Enter·number·of·points·received·for·assignment·1 :10↵ Enter·number·of·possible·points·for·assignment·1 :10↵ Enter·number·of·points·received·for·assignment·2 :7↵ Enter·number·of·possible·points·for·assignment·2 :12↵ Enter·number·of·points·received·for·assignment·3...
Employee Net Pay Kenneth McFarland's weekly gross earnings for the week ending December 18 were $2,960,...
Employee Net Pay Kenneth McFarland's weekly gross earnings for the week ending December 18 were $2,960, and his federal income tax withholding was $621.6. Assuming the social security rate is 6% and Medicare is 1.5% of all earnings, what is McFarland's net pay? If required, round your answer to two decimal places. $
The payroll records of Speedy Software show the following information about Marsha Gottschalk, an employee, for...
The payroll records of Speedy Software show the following information about Marsha Gottschalk, an employee, for the weekly pay period ending September 30. Gottschalk is single and claims one allowance. Compute her Social Security tax (6.2%), Medicare tax (1.45%), federal income tax withholding, state income tax (1.0%), and net pay for the current pay period. (Use the withholding table in Exhibit 9A.6) (Round your final answers to 2 decimal places.) total (gross) earning for current pay period: $610 cumulative earnings...
1. An employer has one employee who earned $4,000 his first month of employment. The employee’s...
1. An employer has one employee who earned $4,000 his first month of employment. The employee’s federal income tax withholding (FITW) is $600, and the employee has voluntary monthly deductions of $350 for health insurance and $50 for union dues. The FICA tax rate for Social Security is 6.2% and the FICA tax rate for Medicare is 1.45%. The employer's FUTA tax rate is 0.6% and the SUTA tax rate is 5.4%. (Note: The limit for FICA Social Security is...
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT