0% found this document useful (0 votes)
51 views4 pages

10 ICSE Computer Science Preparatory

The document is a preparatory examination paper for Class X ICSE in Computer Applications at St. Mira's High School, Bangalore. It consists of two sections: Section A requires answering all questions, while Section B allows students to choose any four questions. The paper covers various topics in Java programming, including data types, methods, and object-oriented concepts.

Uploaded by

gmr6140
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
51 views4 pages

10 ICSE Computer Science Preparatory

The document is a preparatory examination paper for Class X ICSE in Computer Applications at St. Mira's High School, Bangalore. It consists of two sections: Section A requires answering all questions, while Section B allows students to choose any four questions. The paper covers various topics in Java programming, including data types, methods, and object-oriented concepts.

Uploaded by

gmr6140
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 4

ST.

MIRA’S HIGH SCHOOL


Bangalore.

Preparatory Examination 2023-24


SUBJECT : COMPUTER APPLICATION
Class : X ICSE Max Marks – 100
Time : 2-00 Hrs. Min. Marks – 32
_________________________________________________________________________________

Answers to this Paper must be written on the paper provided separately.


You will not be allowed to write during the first 15 minutes.
This time is to be spent in reading the question paper.
The time given at the head of this Paper is the time allowed for writing the answers.

This Paper is divided into two Sections.


Attempt all questions from Section A and any four questions from Section B.
The intended marks for questions or parts of questions are given in brackets[ ].
__________________________________________________________________________________

SECTION – A
(Answer all questions from this section)
Question – 1:
Choose the correct answer and write the correct option: [20]
1. Name the feature of java depicted in the below picture:

(a) Inheritance (b) Data abstraction.


(c) Polymorphism (d) Encapsulation
2. The _______ is called an instance of class
(a) attribute (b) object (c) state (d) features
3. Which of the following is a non-primitive data type?
(a) int (b) double (c) char (d) String
4. Which of the following is the correct procedure of logical operators?
(a) !, &&, || (b) &&, !, || (c) ||, !, && (d) &&, ||,!
5. What of the following is not a java reserved word?
(a) private (b) public (c) break (d) total
6. Given: int p=55/0;
Name the type of error in the given statement:
(a) Syntax (b) Logical (c) Runtime (d) Executional
7. Given d= Math.min(-15.5, -19.5); What data type will you refer for the variable d?
(a) int (b) float (c) double (d) None
8. If m, n, p are the three integers, then which of the following holds true, if(m==n)&&(n!=p)?
(a) ‘m’ and ‘n’ are equal (b) ‘n’ and ‘p’ are equal
(c) ‘m’ and ‘p’ are equal (d) none
9. Which of the following statements will terminate the premature execution of a program?
(a) System.exit(0) (b) break (c) stop (d) end
10. The loop within another loop is called a:
(a) double loop (b) embedded loop (c) circular loop (d) nested loop
11. Each primitive data type belongs to a specific:
(a) block (b) object (c) wrapper class (d) none

Page 1 of 4
12. A dimensional array is also known as:
(a) Subscripted variable (b) actual variable
(c) Compound variable (d) none
13. If a string contains 12 characters, what will be the index of the last character?
(a) 12 (b) 11 (c) 10 (d) 0
14. A method body is enclosed within a pair of:
(a) { } (b) [ ] (c) ( ) (d) under a rectangular box
15. A method with many definitions is called:
(a) Multiple method (b) method overloading
(c) Floating method (d) none
16. Which of the members can be accessed globally?
(a) Default (b) Public (c) Protected (d) Interface
17. A package is a:
(a) Collection of data
(b) Collection of functions
(c) Collection of classes
(d) A nested class
18. A constructor is always:
(a) private (b) protected (c) secure (d) public
19. Which type of data is not accessed in a derived class?
(a) public (b) private (c) protected (d) none
20. What is the another name of multilevel inheritance?
(a) Single inheritance (b) Nested inheritance
(c) Multiple inheritance (d) Derived inheritance

Question – 2:

1. Write the purpose of the following functions?


(a) nextInt() (b) nextLine() [2]
2. The following is a segment of a program:
x = 1; y = 1;
if(n>0)
{
x = x+1;
y = y+1;
}
What will be the value of x and y, if n assumes a value:
(a) 1 (b) 0 [2]
3. Differentiate between isUpperCase() and toUpperCase [2]
4. Give the output of the following program snippet:
int m[] = {2, 4, 6, 8};
System.out.println(m[1] + ‘ ‘+m[2]); [2]
5. How does endsWith() and startsWith() differ? Explain with an example [2]
6. What are the advantages of defining a method in a program? [2]
7. What is the role of the keyword void in declaring methods? [2]
8. Define:
(a) Instance variable (b) local variable [2]
9. Explain the following terms:
(a) Constructor with default argument
(b) Constructor overloading [2]
10. Main class by default inherits another class. Explain the given statement [2]

Page 2 of 4
SECTION – B
(Answer any four questions from this section)

Question – 3: [15]

Write a program to accept name and total marks of N number of students in two single subscript arrays
name[ ] and totalmarks[ ].
Calculate and print:
(i) The average of the total marks obtained by N number of students.
[average = (sum of total marks of all the students)/N]
(ii) Deviation of each student's total marks with the average.
[deviation = total marks of a student - average]

Question – 4: [15]

Special words are those words which start and end with the same letter.
Example: EXISTENCE, COMIC, WINDOW
Palindrome words are those words which read the same from left to right and vice-versa.
Example: MALYALAM, MADAM, LEVEL, ROTATOR, CIVIC
All palindromes are special words but all special words are not palindromes.

Write a program to accept a word. Check and display whether the word is a palindrome or only a
special word or none of them.

Question – 5: [15]

Design a class to overload a method volume( ) as follows:


double volume(double r) — with radius (r) as an argument, returns the volume of sphere using the
formula:
V = (4/3) * (22/7) * r * r * r
double volume(double h, double r) — with height(h) and radius(r) as the arguments, returns the
volume of a cylinder using the formula:
V = (22/7) * r * r * h
double volume(double 1, double b, double h) — with length(l), breadth(b) and height(h) as the

V = l*b*h ⇒ (length * breadth * height)


arguments, returns the volume of a cuboid using the formula:

Question – 6: [15]

Define a class called ParkingLot with the following description:


Class name : ParkingLot
Instance variables/Data members:
int vno :To store the vehicle number
int hours :To store the number of hours the vehicle is parked in the parking lot
double bill : To store the bill amount
Member Methods
void input( ) :To input the vno and hours
void calculate( ) :To compute the parking charge at the rate Rs: 3 for the first hour or the part thereof
and Rs 1.50 for each additional hour or part thereof.
void display() :To display the detail
Write a main method to create an object of the class and call the above methods.
Page 3 of 4
Question – 7: [15]

Define a class called BookFair with the following description:


Instance variables/data members:
String Bname :stores the name of the book
double price :stores the price of the book
Member Methods:
(i) BookFair( ) :Constructor to initialize data members
(ii) void input( ) :To input and store the name and price of the book
(iii) void calculate( ) :To calculate the price after discount. Discount is calculated based on the
following criteria
Price Discount
Less than or equal to Rs 1000 2% of price
More than Rs1000 and less than
or equal to Rs 3000 10% of price
More than Rs 3000 15% of price
(iv) void display( ) :To display the name and price of the book after discount
Write a main method to create an object of the class and call the above member methods.

Question – 8: [15]
Write a program to input a number and check and print whether it is a Pronic number or not. [Pronic
number is the number which is the product of two consecutive integers.]
Examples:
12 = 3 * 4
20 = 4 * 5
42 = 6 * 7 ~ ~ ~ ~ ~ ~ ~ ~

Page 4 of 4

You might also like