Formatting page ...
JAVA FOR SCHOOL SAMPLE PAPER 8 Making Java Fun To Learn ICSE (Class X) --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- COMPUTER APPLICATIONS (Theory) (Two hours) 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 (40 Marks) Attempt all questions Question 1. (a) (b) Mention any two rules for naming identifiers. How do we invoke a constructor? Explain with an example. [2] [2] (c) Write a Java statement to create an object named 'jfs' of a class 'Computer' that invokes a parameterized constructor that accepts two integer type values. [2] (d) How is the concept of Data Abstraction implemented in Java? [2] (e) Write the expression for the absolute value of 2 [2] +3 . Question 2. (a) (b) (c) Assign the constant value of pi (i.e. 3.142) to a variable mentioning its appropriate data type. [2] Name the Java keyword that: (i) is used to finish the execution of a method. (ii) is used to implement the concept of inheritance. [2] If int A[ ] = {9,8,0,4,5,6,6,8,1,5}; What are the values of 'm' and 'n'?. m = Math.max(Math.pow(A[1],A[2]) , Math.sqrt(A[3])); (d) (e) n = Math.pow(Math.min(A[1],A[7]), A[3]); [2] What is the difference between a String object and StringBuffer object? Write a Java statement to check whether two string object 's1' and 's2' are equal or not, using compareTo() function. [2] [2] This Paper consists of 4 printed pages. TSP008 www.javaforschool.com Turn over
|