0% found this document useful (0 votes)
1 views

Class IX Project Computer Applications (2)

The document outlines a computer application project for Class IX, consisting of various Java programming tasks such as checking leap years, determining triangle validity, and identifying special numbers like Kaprekar and Amicable numbers. It also includes practical applications like an ATM program and a hotel menu program. The project must be hand-written, presented in a shoelace file, and include an introduction, index, and acknowledgment.

Uploaded by

samneog2010
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1 views

Class IX Project Computer Applications (2)

The document outlines a computer application project for Class IX, consisting of various Java programming tasks such as checking leap years, determining triangle validity, and identifying special numbers like Kaprekar and Amicable numbers. It also includes practical applications like an ATM program and a hotel menu program. The project must be hand-written, presented in a shoelace file, and include an introduction, index, and acknowledgment.

Uploaded by

samneog2010
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

COMPUTER APPLICATION PROJECT FOR CLASS - IX

1) Write a program in java input year and check whether it is: a leap year or not.

2) Write a java program to check if three given side lengths (integers) can make a triangle or not.

3) Write a program in java to check the number is odd or even.

4) Write a program in java to input three unequal numbers and display the smallest number.

5) Write a program in java to check the given number is positive or not.

6) Write a program to input a number and check whether it is a Kaprekar number or not. Take a
positive whole number n that has d number of digits. Take the square n and separate the result
into two pieces: a right-hand piece that has d digits and a left-hand piece that has either d or d-1
digits. Add these two pieces together. If the result is n, then n is a Kaprekar number.

Examples are 9 (92 = 81, 8 + 1 = 9), 45 (452 = 2025, 20 + 25 = 45), and 297 (2972 = 88209, 88 +209 =
297).

7) Write a program to input 10 integers and print the second largest number. Assume that there is
at least one second largest number in the given set of integers.

For Example,

INPUT: Enter 10 integers:

12 35 46 22 34 56 78 89 23 21

OUTPUT: Second Largest Integer: 78

8) Write a Java program to check whether a given number is a happy number or unhappy number.

Happy number: Starting with any positive integer, replace the number by the sum of the squares of
its digits, and repeat the process until the number equals 1, or it loops endlessly in a cycle which
does not include 1.

An unhappy number is a number that is not happy.

The first few unhappy numbers are 2, 3, 4, 5, 6, 8, 9, 11, 12, 14, 15, 16, 17, 18, 20.

Expected Output

Input a number: 5

Unhappy Number

9) WAP in Java, to create an ATM program for representing ATM transaction. In the ATM program,
the user has to select an option from the options displayed on the screen. The options are related
to withdraw the money, deposit the money, check the balance, and exit.

 To withdraw the money, we simply get the withdrawal amount from the user and remove
that amount from the total balance and print the successful message.
 To deposit the money, we simply get the deposit amount from the user, add it to the total
balance and print the successful message.

 To check balance, we simply print the total balance of the user.

10) Write a Java program to check two numbers are Amicable numbers or not.
Amicable numbers are two different numbers so related that the sum of the proper divisors of
each is equal to the other number.
The first ten amicable pairs are: (220, 284), (1184, 1210), (2620, 2924), (5020, 5564), (6232, 6368),
(10744, 10856), (12285, 14595), (17296, 18416), (63020, 76084), and (66928, 66992).
Expected Output

Input the first number: 220

Input the second number: 284

These numbers are amicable.

11) Mystery Number

A number N is said to be a mystery number if the number can be expressed by the sum of two
numbers. Note that these two numbers must be reverse of each other. It lies between 22 to 198,
i.e. 22<=N<=198.

It is called mystery numbers because these are the multiples of 11, and the sum of place values of
unit (1) and tens (10) place is 11 in decimal numeration.

12) Krishnamurthy Number

Krishnamurthy number is another special number in Java. A number is said to be Krishnamurthy if


the factorial sum of all its digits is equal to that number. Krishnamurthy number is also referred to
as a Strong number.

13) Create a Java program that converts the given number into words. For example, if the given
number is 54,297 then the output should be Fifty-Four Thousand Two Hundred Ninety-Seven.

14) Create a java program to accept a number and check whether the number is perfect number or
not. A number is called perfect number, if the sum of all factors (except number itself) of the
number is equal to that number. (For e.g. 6 is a perfect number. Factors are 1, 2 & 3 and the sum is
1+2+3 = 6.)

15) Write a menu driven program to input a month number between 1 to 12 and print the
corresponding month name. That is for 1 display January, for 2 display February for 3 display
March, etc.
16) Write a program to input three integers and check whether it forms a Pythagorean triplet or
not. A set of three integers is said to be a Pythagoren triplet if the sum of the squares of any two
integers is equal to square of the third integer. Example, (3, 4, 5), (5, 12, 13), and (7, 24, 25).

17) Java Hotel Menu Program that creates hotel menu to help customers place orders.

Sample Output:

18) An interesting method of multiplication of integers (not very large numbers) is as follows.

The method can be illustrated by the following example. If the numbers 17 and 19 are to be
multiplied, they are put at the top of two columns as shown below:

17 19

The numbers at the left hand side is successively divided by 2 (integer division) while the other is
successively multiplied by 2. The results are written one below the other in their respective
columns. The process is repeated till the column containing the division results reached 1. At this
stage all the numbers in the right hand column are struck off where numbers corresponding to it
on the left hand column is even.

17 19

8 (even) 38

4 (even) 76
2 (even) 152

1 304

Now the remaining numbers on the right hand side are added: 19+304=323 which is equal to the
product of 17 and 19.

Write a program to input two 2-digit numbers and find their product using the above technique.

19) The 1st day of 2021 was Friday, write a Menu driven program to input any day number within
the month of January and print which day was it. Also check whether the day number entered is a
valid date or not.

For example,

Input: Enter day number: 20

Output: Wednesday

Input: Enter day number:30

Output: Saturday

Input: Enter day number:34

Output: Invalid day number

20) Sphenic Number

A positive integer n is called a sphenic number if the product of factors of the given number (n) is
exactly three and all factors are prime. In other words, if n is a sphenic integer then n=p * q * r (p,
q, and are three distinct prime numbers and their product are n).

A number will be a sphenic number if the product of three distinct prime numbers gives the
number itself. The sphenic numbers have exactly 8 divisors.

INSTRUCTION:THE PROJECT TO BE MADE IN A SHOE LACE FILE AND TO BE COVERED WITH BROWN
PAPER AND SHOULD BE HAND WRITTEN. IT SHOULD HAVE YOUR NAME CLASS AND SECTION
WRITTEN ON TOP OF THE FILE. THE PROJECT SHOULD HAVE AN INTRODUCTION, INDEX, AND
ACKNOWLEDGEMENT TO START WITH.

You might also like