Computer Science, asked by bhartimaths86, 7 months ago

1. Write a program to input age, gender (‘M’ for Male and ‘F’ for Female) and the monthly income earned by a person. If the age of the person is more than 65 years then display the message “Age Exceeded Taxation”, otherwise compute the tax as per the below given table: Annual Income (AI) Income tax (Female) Income Tax (Male) 1,00,000 && 3,00,000 && 10,00,000 (AI – 10,00,000) * 5% + 30,000 (AI – 10,00,000) * 6% + 50,000 Display the age, gender, monthly income, annual income and the total tax to be paid by the person. Write suitable variable description.

Answers

Answered by sooryakrishna
0

Explanation:

find the answer and display it by using system.out.println ( here you write the answer which we should display );

Answered by Anonymous
1

import java.util.*;

public class Tax

{

public static void main (String args [])

{

Scanner in = new Scanner (System.in);

int b,c;

String a , g ;

System.out.println(" enter your name:");

a = in.nextLine();

System.out.println(" enter your age:");

b = in.nextInt();

System.out.println("enter your gender (male or female) :");

g = in.nextLine();

System.out.println(" enter your taxable income:");

c = in.nextInt();

if (b > 65)

{

System.out.println("Wrong Category !");

}

else if (c <= 250000)

{

System.out.println(" Nil ");

}

else if (c > 250000 && c <= 500000)

{

c = ((c - 160000)* 10/100);

System.out.println(" Payable tax = Rs" +c);

}

else if (c> 500000 && c<= 1000000)

{

c = ((c-500000) * 20/100 + 34000);

System.out.println( "Payable tax = Rs" +c);

}

else if (c> 1000000)

{

c = ((c- 1000000) * 30/100 + 94000);

System.out.println(" Payable tax = Rs" +c);

}

}

}

Similar questions