Computer Science, asked by tguruji78, 7 months ago

Write a program in Java to input total income, not taxable income and tax rate, then

compute and display the tax for the taxable income.

[Suppose total income= 1800000/-,not taxable income= 600000/-, tax rate= 17.5%]​

Answers

Answered by BrainlyProgrammer
7

Answer:

Hello friend,

Here is your answer...done using scanner class

import java.util.*;

class income

{

public static void main (String ar[])

{

Scanner Sc=new Scanner (System.in)

double ti=0.0,taxi=o.o,tax=0.0;

System.out.println("Enter total income and taxable income");

ti=sc.nextDouble();

taxi=sc.nextDouble();

tax=(ti/taxi)*100;

//I m not sure about formula of tax rate....

System.out.println("Tax rate:"+tax);

}

}

Similar questions