0% found this document useful (0 votes)
36 views1 page

Delhi Public School Ghaziabad Informatics Practices Assignment - 6 Simple Program Using Net Beans Java

The document contains instructions for 11 programming assignments involving basic conditional and arithmetic operations in Java: 1. Write a program to input 3 numbers and print the greatest and smallest using switch case. 2. Write a program to determine if a given number is even or odd using ternary operators. 3. Write a program to input a number and print its square if even, cube if odd. The remaining assignments involve basic calculations like calculating employee salary components, temperature conversion, variable swapping, eligibility checking, leap year determination, electricity bill calculation, income tax calculation, and character classification.

Uploaded by

mehulagarwal095
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
36 views1 page

Delhi Public School Ghaziabad Informatics Practices Assignment - 6 Simple Program Using Net Beans Java

The document contains instructions for 11 programming assignments involving basic conditional and arithmetic operations in Java: 1. Write a program to input 3 numbers and print the greatest and smallest using switch case. 2. Write a program to determine if a given number is even or odd using ternary operators. 3. Write a program to input a number and print its square if even, cube if odd. The remaining assignments involve basic calculations like calculating employee salary components, temperature conversion, variable swapping, eligibility checking, leap year determination, electricity bill calculation, income tax calculation, and character classification.

Uploaded by

mehulagarwal095
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 1

DELHI PUBLIC SCHOOL GHAZIABAD INFORMATICS PRACTICES ASSIGNMENT 6 SIMPLE PROGRAM USING NET BEANS JAVA 1.

. WAP to input three numbers and print the greatest as well as smallest using switch case. 2. WAP to find whether a given number is even or odd using conditional operator. 3. WAP to input a number. If the number is even, print its square otherwise print its cube. 4. WAP to input employee code, name and basic salary of an employee and calculate the following values: HRA 40 % of basic salary DA 10 % of basic salary CCA 5 % of basic salary GS Basic + HRA + DA + CCA PF 10 % of GS IT 10 % of GS NS GS (PF + IT) Display all the values using appropriate swing tools. 5. WAP to input the temperature in Fahrenheit and convert it into Celsius and vice versa. 6. WAP to swap the values of two integer variables (a) Using extra variable (b) Without using extra variable 7. WAP to input the age of a person and check that he is eligible for license for not. 8. WAP to check that a given year is a leap year or not. 9.An electricity board charges according to the following rates: For the first 100 units - 40 paisa per unit. For the next 200 units - 50 paisa per unit. beyond 300 units - 60 paisa per unit. All users are charged meter charges also, which are Rs. 50/10. WAP to input monthly salary from the user and calculate the income tax according to the following rules: Salary income tax >=9000 40% of the salary 7500-8999 30% of the salary <7500 20% of the salary 11.WAP to input a character and check that its a small letter, capital letter, a digit or a special symbol.

You might also like