Trending ▼   ResFinder  

ICSE Prelims 2018 : Computer Applications (Nazareth School, Bangalore)

4 pages, 33 questions, 22 questions with responses, 34 total responses,    2    0
Sudha Sam
Nazareth School, Bangalore
+Fave Message
 Home > sudha98 >   F Also featured on: School Page icse

Instantly get Model Answers to questions on this ResPaper. Try now!
NEW ResPaper Exclusive!

Formatting page ...

NAZARETH SCHOOL FIRST TERM EXAMINATION-October,2017 CLASS: X Computer Application (Theory) TOTAL MARKS: 100 TIME: 2 HOURS Question 1 1. Name any two OOP s principles. [2] 2. What are identifiers? [2] 3. Name the primitive data type in Java that is: i) a 64 bit integer and is used when you need a range of values wider than those provided by int. [1] ii)a single 16-bit Unicode character whose default value is \u0000 . [1] 4. What are the types of casting shown by the following examples? [2] i) double x= 15.2; ii) int x=12; int y =(int ) x; long y=x; 5. What is the difference between break and continue statement? [2] Question 2 1. Convert the following do-while loop into for loop [2] int i=1; int d=5; do{ d= d*2; System.out.println(d); i++; } while (i<=5); 2. Identify the following as valid variable names .State the reason [2] i) _345 ii)c*345 iii) name$ iv) student 3. What principle is used to implement function overloading? [2] 4. Define function. 5. What is the purpose of return statement? [2] [2] Question 3 1.How many times will the following loop execute ? What value will be returned? [2] Int x=2,y=50; do{ ++x; y-=x++; }while(x<=10); return y; 2. Write the java expression for i) a b2 +cd 2 ii) 3 4 r3h [2] 3. If int n[ ]={1,2,3,4,5,7,8,9,16}. What are the values of X and Y? [2] X=Math.pow(n[4],n[2]); Y=Math.sqrt(n[5]+n[7]); 4. Define class as user defined data type. [2] 5. What is an infinite loop? Give example. [2] Question 4 1. What will be the output of the following code? [2] i) int K=5,j=9; ii) double b=-15.6; K+=K++ - ++j +K; double a = Math.rint(Math.abs(b)); System.out.println( k= +K); System.out.println( a= +a) 2. What are library classes? Give an example. [2] 3. State the output of the following program. when x=9 and x=10 [2] If(x++ ==11) System.out.println( Result is 11 ); else if(++x==10) System.out.println( Result is 10 ); else System.out.println( Result is neither 10 nor 11 ); 4. Write a function prototype of a function search which receives a sentence sentnc and a word wrd and returns 1 or 0. [2] 5. What is Access specifier? [2] Question 5 A showroom is announced the festical discounts on the purchase of items. Amt of purchase Discount in % Handloom items Less than Rs 1000 2% 5% Rs.1000 to Rs.1500 20% 25% Rs.5000 to Rs.10000 40% 50% Above 10000 50% 60% Write a Java program to complete the net amt paid by the customers.Assume all required values to be input by the users. Question 6 Define a class called Library with the following description: Instance variable /data members: Int acc_num :Stores the accession number of the books String title :stores the title of book String :stores the name of author Member methods: void input() : To input and store the accession number ,title and author void compute() :To accept the number of days late, calculate and display the fine charges at the rate of per day void display() : To display the details in the following format: Accession Number Title Author ______________ ______ ______________ Write the main method to create an object of the class and call the above member methods. Question 7 Using the switch statement, write a menu driven program: i) To check and display whether input by the user is composite or not(A composite is composite if it has one or more than one factor excluding 1 and number itself. Example 4,6,8,9..... ii) To find the smallest digit of an integer that is input sample input :6524 Sample output : Sample digit is 2. For an incorrect choice, an appropriate error message should be displayed. Question 8 Design a class to overload a function area() as follow: i)double area (double a ,double b,double c) with three double arguments, returns the area of a scalene triangle using the formula: area = s ( s a ) ( s b ) (s c) where s = a+b+ c 2 ii) double area (int a ,int b,int height ) with three integer arguments, returns the area of a trapezium using the formula: area = 1 height (a+b) 2 iii) double area (double diagonal1,double diagonal2) with two double arguments, returns the area of a rhombus using the formula: area = 1 2 diagonal1 x diagonal2 Question 9 Write a menu driven program to perform the following: a)To print the series 0,3,8,15,24, n (value of n is to be an input by the user). ii)To find the sum of the series s=1/2 +3/4+5/6+7/8+ .19/20 Question 10 Write a program to input and store roll numbers, names and marks in 3 subjects of n number students in five single dimensional arrays and display the remark based on average marks as given below: (The maximum marks in the subject are 100) Average marks = Total marks/3 Average marks Remark 85-100 EXCELLENT 75-84 DISTINCTION 60-74 FIRST CLASS 40-59 PASS Less than 40 POOR

Formatting page ...

Top Contributors
to this ResPaper
(answers/comments)


Sejal Gupta

(24)

Ritin Malhotra

(4)

Shreyas JV

(3)

Aruna Rander

(3)

Formatting page ...

Formatting page ...

 

  Print intermediate debugging step

Show debugging info


 

 

© 2010 - 2025 ResPaper. Terms of ServiceContact Us Advertise with us

 

sudha98 chat