Icjecapu 15
Icjecapu 15
Sample Paper 15
ICSE Class X 2024-25
COMPUTER APPLICATIONS
Time: 2 Hours Max. Marks: 100
General Instructions :
1. Answers to this Paper must be written on the paper provided separately.
2. You will not be allowed to write during the first 15 minutes.
3. This time is to be spent in reading the question paper.
4. The time given at the head of this Paper is the time allowed for writing the answers.
5. This Paper is divided into two Sections.
6. Attempt all questions from Section A and any four questions from Section B.
7. The intended marks for questions or parts of questions are given in brackets [ ].
SECTION A
Attempt all questions from this part.
QUESTION 1.
Choose the correct answer and write the correct option.
(Do not copy the question, write the correct answers only.)
(vi) What term describes a construct that combines various primitive types to use them as a single unit?
(a) Object (b) Class
(c) Abstraction (d) Variable
(ix) When an expression contains data types such as double, int, float, and long, into which data type will the
entire expression be promoted??
(a) long (b) int
(c) double (d) float
(x) Which of the following classes is the superclass of both the String and StringBuffer classes?
(a) java.util (b) java.lang
(c) ArrayList (d) None of these
(xii) Which of the following is a method with the same name as its class?
(a) finalise (b) delete
(c) class (d) constructor
(xiv) It means that the same operations may behave differently on different classes.
(a) Inheritance (b) Polymorphism
(c) Encapsulation (d) Data abstraction
(xv) Which method of the String class is used to retrieve a single character from a string object?
(a) CHARAT( ) (b) charat( )
(c) charAt( ) (d) CharAt( )
(xvii) Assertion (A) : Encapsulation prevents the client from seeing its internal view.
Reason (R) : Encapsulation is implemented in Java using interfaces and abstract classes.
(a) Both Assertion (A) and Reason (R) are true and Reason (R) is a correct explanation of Assertion (A).
(b) Both Assertion (A) and Reason (R) are true and Reason (R) is not a correct explanation of Assertion
(A).
(c) Assertion (A) is true and Reason (R) is false.
(d) Assertion (A) is false and Reason (R) is true.
(xviii) Read the following text, and choose the correct answer:
Method overloading enables multiple methods to share the same name but have different signatures.
The signature can vary based on the number of input parameters, the type of input parameters, or a
combination of both. In Java, method overloading is also referred to as Compile-time Polymorphism, Static
Polymorphism, or Early Binding.
What is the process of defining two or more methods within same class that have same name but different
parameters declaration?
(a) Method overloading (b) Method overriding
(c) Method hiding (d) None of the mentioned
QUESTION 2.
(ii) How many times will each of the following loops execute? Also, identify which loop is entry-controlled and
which is exit-controlled.
Loop 1 Loop 2
int n=10, sum=0; int n=10, sum=0;
while(n>1) do
{ {
sum+=n; sum +=n;
n-=3; n—=3;
} } while(n>1);
(iii) The following code contains errors. Please rewrite the corrected version, underlining all the changes made.
Int x=1; y=9;
do;
{
++x;
y— =x— —;
}
whi1e(x<9)
return y
(vii) Given x = 40 and y = 20, determine the result of the following expressions:
(a) x+ =y;
(b) x%=y;
(viii) Write the Java statement for the following mathematical expression:
3 3
m= a +b
^a + b h
(ix) What will be the content of L after executing the following code?
String F1=“I#N#T#E#R”, F2;
//(#) represents a space
F2=F1.trim();
int L = F2.length();
System.out.print(L);
(x) “Assume that x1 and x2 are two variables of type double, and you want to add them as integers and assign
the result to an integer variable. Write a Java statement that performs this operation.”
SECTION B
Attempt any four questions from this section.
QUESTION 3.
Write a Java program to compute tax for residents of Mumbai. Define a class named TaxCalculator based on
the class description provided.
QUESTION 4.
Define a Student class with the following instance variables: name, age, m1, m2, m3 (marks in three subjects),
maximum (highest mark), and average.
4. display(): A method to display the student’s name, age, marks in three subjects, maximum, and average.
Write a main method to create an object of the Student class and call the above methods.
QUESTION 5.
QUESTION 6.
QUESTION 7.
Write a Java program to sort an array in ascending order using the bubble sort algorithm.
QUESTION 8.
Write a program to accept the year of school graduation as an integer from the user. Use the binary search
technique on the sorted array of integers provided below. If the entered year is found in the array, display
“Record exists”; otherwise, display “Record does not exist.”
{1981, 1986, 1992, 1995, 1998, 2002, 2005, 2006, 2008, 2009}
******