Formatting page ...
VIVEKANANDA MISSION SCHOOL First Term Examination, 2022-23 Class-XI Subject: Computer Science (Paper -1, Theory) Time:3 Hrs. Full Marks: 70 (Candidates are allowed additional 15 minutes for only reading the paper. They must NOT start writing this time.) (All working, including rough work, should be done on the same sheet as the rest of the answer. The intended for questions or parts of questions are in brackets [ 1.) (Answer all the questions) PART I(20 Marks) [1x10-10] QuestiopM: What will be the output of the following for(System.out.print("FLOWER"):;System.out.print("YELLOW"); System.out.printFRUITS")) break; ComPil a) empker error b) FLOWER FRUITS c) FLOWRYELLOW c) FLOWER YELLOW FRUITS eNone of the Above KWhich for loop has range of similar indexes of f used in forli =0;i <n;i++) ? a) for (i = n; i>0; i--) Subject:Computer Science (Paper 1, Theory) Class -XI 2022-2023 (2) Question 2: 21 Write two nExplain continue statement with example. What will be the output of the following? ) f o r (i = n-1; i>0: i--) )for(i =n-1; i-1; i-) e)None of the Above Rn) 21 What is escape sequence? Give example. differences between if and switch. b)for (i= n; i>=0;i-) If you have to make decision based following is best suited? on multiple choices, which 21 [4 int k,P of the for k=1 k 3 ; k++) if a) b)f-else for (p=1: p<=k; p++) System.out. printn(++p+k++)}; c)f-elseAll of the above How many timesthe following loop will be executed? PART-1I (50 Marksl Group A forintx 1;x=3; X++) a) Three times b) c) Four times Forever Question3 e)Compilation error I f switch is used, then a) defaut case must be present ( )None ofthe above write S t a t e whether the following expression is a Tautology, Contradiction or a Contingency, with the help of a tuth table: its: A) Inverse (Converse What is principle of duality? R Zv-I0X>YY>z)] 2] Simplity the following expression, using Boolean laws:. (X+Z).(X.Y + Y.Z) + X.Z+Y [mention the laws used] Y-NE iv Draw the diagram of F(A,B,C) = A'BC+AB'C+C using basic gates. (y Find the dual of: X.Y+X.Y" =X+0 What is the base of a numbersystem? Write one disadvantage of using Array? Subject: Camputer Science (Paper 1, Theory) Subject: Computer Science (Paper 1, Theory) [21 (101.11),X1.1)=1), uestion 4 State Distributive law. Prove any one of it using Truth Table. (vi) What is Encapsulation? i)if (P0) 131 7547),+(?)- (ADc3)6 b) defaut case, if used, should be the last case c)default case, if used, can be placed anywhere then 21 t2] Perfom (ABC)(176D),, using 16's cormplement Perfom (101011),-(10110), using 2's complement. ) Represent (-21), in 8 bit sign magnitude format. c)Never Class XI 2022-2023 21 Class XI 2022-2023 4) Group B Question7: (Each program should be written in such a way that it clearly depicts the iogic of the problem. This can be achieved by using comments in the program. Flowcharts and Algorithms are not required. The programs must be written in Java.) Questio: Write a menu [10 driven program a program to initialize ()Display the second 1D array ot size and do the following I71 them highest without sorting the array array 7 Rearranged Array: A number is unique or not. an minimum element in tha array and swap Find the maximum and Example: Initialize (using wcikeh case) to check: A number is disarium or not. 2 Write 7 85 25 45 78 40 25 45 78 85 40 Second highest: 78 [A number is said to be disarium if sum of its digits powered with their respective position is equal to the original number. For example 89 as 8'+92 89. A numberis said to be unique if the digits are not duplicate. For example, Question : Write a program to input number of units consumed by 5) a customer. Calculate and display the bill amount on the basis of the iollowing: 20, 56, 9863, 145] Taritf Table: Number of Unit Rate per unit Write a program to input row size, column size and the elements of a 2D array. Display all the tech numbers present in this array with the coresponding row and column index. First 100 units Rs 10.00 Next 200 units Rs.12.00 [A tech number has even number of digits. If the number is split in two equal halves, then the square of sum of these halves is equal to the number itself. Above 300 units Rs. 15.00D Question6 [8 Example A surcharge of 2.5% wilf be charged it the number ot units consumed is above 300 units. Consider the number 3025 Square of sum of the halves of 3025 =(30+25) (55) 3025 is a tech number.] Subject: Computer Science (Paper 1, Theory) Class XI 2022-2023 Subject: Computer Science (Paper 1, Theory) Class 0220I
|