Sharp Tutorial
Income Tax Program in Java

Python

Java

C

C++

HTML/CSS

Java Script

PHP

SQL

C Programs

Week 1

  • Ans of Question 1
  • Ans of Question 2
  • Ans of Question 3
  • Ans of Question 4
  • Ans of Question 5

Week 2

  • Ans of Question 1
  • Ans of Question 2
  • Ans of Question 3
  • Ans of Question 4
  • Ans of Question 5

Week 3

  • Question 1
  • Question 2
  • Question 3
  • Question 4
  • Question 5

Week 4

  • Question 1
  • Question 2
  • Question 3
  • Question 4
  • Question 5

Week 5

  • Question 1
  • Question 2
  • Question 3
  • Question 4
  • Question 5

Solution of java assignment questions

Java Program to Calculate the tax

import java.util.*;
class Tax
{
	public static void main(String args[])
	{
		System.out.println("Enter the Salary ");
		Scanner sc= new Scanner(System.in);
		int salary=sc.nextInt();
		int taxAmt=0;
		if(salary<=50000)
		{
		  taxAmt=0;	
		}
		if(salary>50000 && salary<=60000)
		{
		  taxAmt=(salary-50000)*10/100;	
		}
		if(salary>60000 && salary<=150000)
		{
		  taxAmt=(salary-50000)*20/100;	
		}
		if(salary>150000)
		{
		  taxAmt=(salary-50000)*30/100;	
		}
			
        System.out.println("the tax to be paid is "+taxAmt);

    }

}
 

Enquiry about Course

Ask your Question

Watch video in full size

Video tutorial

Click To Read: SQL Tutorial With Easy Example Queries.

Follow by Email
Facebook
Facebook
fb-share-icon
YouTube
Copyright © Sharp Tutorial
Build with WordPress
Wordpress Social Share Plugin powered by Ultimatelysocial
Sharp Tutorial