ICSE 2010 Computer Application


Answer to this ICSE 2010 Computer Application ICSE Board 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 is the time allowed for writing the answer.
——– ——– ——– ——– ——- ——- ——– ——- ——-
This paper is divided into two Sections. Answer all Questions from Section A and any four questions from Section B. The intended marks for questions or parts of questions are given in [].
——– ——– ——– ——– ——- ——- ——– ——- ——-

SECTION A(40 Marks)
Attempt all questions.

Question 1.                                                      [10]
(a) Define the term Byte Code.

(b) What do you mean by type covertion? How is implicit convertion is different from explicit convertion?

(c) Name two jump statements and their use.

(d) What is an Exception? Name two Exception handling blocks.

(e) Write two advantages of using function in a program.

Question 2.                                                      [10]
(a) State the purpose and return data type of the String functions (i) indexOf() (ii) compareTo()

(b) What is the result store in x, after evaluating the following expression.
int x=5; x = x++ * 2 + 3 * –x;

(c) Differentiate between static and non-static data member.

(d) Write the difference between length and length() function.

(e) Differentiate between private and protected visibility modifier.

Question 3.
(a) What do you understand by the term data abstraction?Explain with an example.

(b) What will be the output of the following code?(i)int m=2;int n=15;
for(int i=1;i<5;i++);
(ii)char x=’A’;int m;

(c) Analyze the following program segment and determine how many times the body of loop will be executed and what will be the output of the program segment.
int k=1,i=2;

(d) Give the prototype of the function check which recies achsrscter ch and an integer n and returns true or false.

(e) State two features of constructor.

(f) Write a statement esch to perform the following task on a string:
(i)Extract the second last charastewr of a word stored in a variable wd.
(ii)Check if the second character of a string str is in uppercase.

(g) What will the following function return when executed?

(h) (i)Why is an object called an instance of a class?
(ii)What is the use if the keyword import?

SECTION B (60 Marks)
Attempt any four questions from this Section. The answers in this Section should consist of the Program in BlueJ environment with Java. Each program should be written in using Variable descriptions/Mnemonic Codes such that the logic of the program is clearly depicted. Flow charts and Algorithms are not required.

Question 4.
Write a program to perform binary search on a list of integers given below,to search for an element input by the user ,if it is found display the element along with its position,otherwise display the message”Search element not found’

Question 5.
Define a class student described as below;
Data members/instance variables:
name,age,m1,m2,m3(marks in 3 subjects),maximum ,average
Member methods:
(i)A parameterised constructor to initialise the data members
(ii)To accept the details of a student
(iii)To compute  the average and the maximum out of three marks
(iv)To display the name,age,marks in 3 subjects,maximum and avarage
Write a main method to create an object of a class and call the above member methods


Question 6.
Shasha Travels Pvt Ltd. gives the following discount to its customers:
Ticket amount                       Discount
Above RS.7000                       18%
Rs 55001 to Rs 70000                16%
Rs 35001 to Rs 55000                12%
Rs. 25001 to Rs 35000               10%
less than 25001                     2%
Write a program to input the name and ticket amount for the customer and calculate the discount amount to be paid.Display the output in the following format for each customer
Sl.No.    Name    Ticket Charges        Discount         Net amount
(Assumer that there are 15 customers ,first customer ia given the Sl.No. 1,next customer 2……and so on)

Question 7.
Write a menu driven program to accept a number and check and display whether it is a prime number or not Or an automorphic number or not.(use switch case statement)
a)prime number :a number is said to be prime if it is divisible only by 1 and itself and not by any other number.examples:3,5,7,11,13,etc
b)Automorphic number :An automorphic number is a number which is contained in the last digits of the square.
example 25is an automorphic number as its square is 625 and 25 is present as the last two digits.

Question 8.
Write a program to store 6 elements in an array P,and 4 elements in an array Q and produce a third array R,containing all the elements of array P and Q
Example: input                     Output
P[]        Q[]                      R[]
4          19                       4
6          23                       6
1          7                        1
2          8                        2
3                                   3
10                                 10

Question 9.
Write a program to input a string in uppercase and print the frequency of each character.
A                    2
C                    1
D                    1
E                    2
H                    1
M                    1
O                    1
P                    1
R                    3
T                    1
U                    1
W                    1

= * = * = * = * = * =

Leave a Comment