12 Computer Science SP 01

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 12

myCBSEguide

Class 12 - Computer Science


Sample Paper - 01 (2023-24)

Maximum Marks: 70
Time Allowed: : 3 hours

General Instructions:

Please check this question paper contains 35 questions.


The paper is divided into 4 Sections- A, B, C, D and E.
Section A, consists of 18 questions (1 to 18). Each question carries 1 Mark.
Section B, consists of 7 questions (19 to 25). Each question carries 2 Marks.
Section C, consists of 5 questions (26 to 30). Each question carries 3 Marks.
Section D, consists of 2 questions (31 to 32). Each question carries 4 Marks.
Section E, consists of 3 questions (33 to 35). Each question carries 5 Marks.
All programming questions are to be answered using Python Language only.

Section A
1. State true or false:
Like while, the for loop also works with conditions and truth values.
a) True
b) False
2. Which of the following sublanguages of SQL is used to query information from the database and to insert tuples into, delete tuples from, and modify tuples in the
database?
a) DDL (Data Definition Language)
b) Query
c) Relational Schema
d) DML (Data Manipulation Language)
3. Which of the following is correct to retrieve any character at index 'i' in string 's'?
a) s.__getitem__(i)
b) s.getitem(i-1)
c) s.__getitem__(i-1)
d) s.getitem(i)
4. What is a variable defined outside all the functions referred to as?
a) A local variable
b) An automatic variable
c) A static variable
d) A global variable
5. Computer communication signal which is in the form of the continuous wave is called
a) modulation signal
b) Binary signal
c) digital signal
d) analog signal
6. Which of the following command is used to open a file "c:\pat.txt" for writing as well reading in binary format only?
a) fout = open("c:\ \pat.txt", "wb+")
b) fout = open("c: \pat.txt", "w")
c) fout = open("c:\ \pat.txt", "wb")
d) fout = open("c: \ pat.txt", "w+")
7. Which of the following is a procedural language?
a) Relational Algebra
b) Query Language
c) Tuple Relational Calculus
d) Domain Relational Calculus
8. A relational database consists of a collection of ________.
a) Attributes
b) Tuples
c) Keys
d) Relations
9. To open a file c:\ss.txt for appending data, we use
a. file = open("c:\ \ss.txt", "a")
b. file = open("c:\ \ss.txt", "rw")

Copyright © myCBSEguide.com. Mass distribution in any mode is strictly prohibited.


1 / 12
myCBSEguide
c. file = open(r"c: \ss.txt", "a")
d. file = open(file = "c:\ss.txt", "w")
e. file = open(file = "c:\ \ss.txt", "w")
f. file = open("c:\ res.txt")
a) c, d
b) b, d
c) a, c
d) a, d
10. The collection of functions creates a
a) library
b) software
c) recursion
d) program
11. A pointer variable which contains the location of the first/topmost element of the stack is called ________.
a) Final
b) Top
c) Last
d) First
12. What will be the output of the following Python code?

V = 25
def Fun(Ch):
V=50
print (V, end=Ch)
V *= 2
print(V, end=Ch)
print(V, end="*")
Fun("!")
print(V)

a) 25*50!100!100
b) 50*100!100!100
c) 25*50!100!25
d) Error
13. State true or false:
SSL provides a safe passage for data over Internet.
a) True
b) False
14. What is printed by the following statements?

Dl={"cat":12, "dog":6, "elephant":23, "bear":20}


print("dog" in Dl)

a) False
b) True
c) None of these
d) Error
15. Fill in the blanks:
The SQL ________ clause contains the condition that specifies which rows are to be selected.
16. What is a Firewall in Computer Network?
a) An operating System of Computer Network.
b) A web browsing Software.
c) The physical boundary of Network.
d) A system designed to prevent unauthorized access.
17. Assertion (A): Python does not allow programmers to develop the software for several computing platforms by writing a program only once.
Reason (R): Python is cross platform language.
a) Both A and R are true and R is the correct explanation of A.
b) Both A and R are true but R is not the correct explanation of A.
c) A is true but R is false.
d) A is false but R is true.
18. Assertion (A): The file needs to be properly closed.
Reason (R): If any exception occurs while performing some operations in the file then the program terminates without closing the file.
a) Both A and R are true and R is the correct explanation of A.
b) Both A and R are true but R is not the correct explanation of A.
c) A is true but R is false.

Copyright © myCBSEguide.com. Mass distribution in any mode is strictly prohibited.


2 / 12
myCBSEguide
d) A is false but R is true.
Section B
19. Answer:
1. i. Your friend wishes to install a wireless network in his office. Explain to him the difference between guided and unguided media.
ii. What is the difference between Packet switching and Circuit switching techniques?
2. OR
i. What is demodulation? How is it different from modulation?
20. Write Python code to insert following records into the order-details table.
Database → sales
User id → Admin
Password → salar345
table name → order-details
ORDNUMB PARTNUMB NUMBORD QUOTPRIC
12489 AX12 11 14.95

12495 BT04 1 402.99


12491 BZ66 1 311.95
12498 CX11 2 57.95
21. Identify the types of following literals.
False 'True' "False"

45345 0O434 435.3

OR

Write a program to swap the values of two variables.


22. Answer:
1. How fetchone() method is differ from fetchall() method?
2. Which record will get inserted in the table by following code :
import mysql.connector as sqltor
mycon = sqltor. connect (host = "localhost", user = "learner", passwd = "fast", database ="test")
cursor = mycon.cursor()
query = "INSERT INTO books (title, isbn) VALUES (’{}’, {})".format( 'Ushakiran', '42568987036') cursor.execute(query)
mycon.commit()
23. In the below given code fragments, indicate the data type of each bold part by choosing the correct type of data from the following type.
a. int
b. float
c. bool
d. str
e. function
f. list of int
g. list of str
i. L = inputline.split( )
while L != ( ) :
print(L)
L = L[1 :]
ii. L = ['Hiya', 'Zoya', 'Preet']
print(L[0] + L[1])

OR

How to access the tuple?


24. Write a program to count the number of uppercase letters in a text file "Article.txt".

OR

Consider the following code:

f = open("mytry", "w+")
f.write("0123456789abcdef")
f.seek(-3,2) //statement1
print(f.read(2)) //statement2

Explain statement1 and give output of statement2.


25. Differentiate between fruitful functions and non-fruitful functions.

Copyright © myCBSEguide.com. Mass distribution in any mode is strictly prohibited.


3 / 12
myCBSEguide
Section C
26. Answer:
1. How can you add following data in empty dictionary?
Keys Values

A One

B Two
C Three

D Four
2. Find the output of given code.

s = 'Hello'
s1 = '20'
s2 = 'World'
a = 4
b = 6
print(s+s2)
print(a+b+16)
print(s1*a)
print(s*2)
print(s + s2 + s1)

27. What will be the output of following programs?


i. num = 1
def myfunc():
return num
print(num)
print(myfunc())
print(num)
ii. num = 1
def myfunc():
num = 10
return num
print(num)
print(myfunc())
print(num)
iii. num = 1
def myfunc():
global num
num = 10
return num
print(num)
print(myfunc())
print(num)
iv. def display ():
print ("Hello", end = ' ')
display()
print("there!")
28. What do you understand by Primary Key? Give a suitable example of Primary Key from a table containing some meaningful data.

OR

Consider the following table with their fields


EMPLOYEE ( E_CODE, E_NAME, DESIG, SALARY, DOJ)
List the names, salary, PF, HRA, DA of all the employees in the EMPLOYEE table. HRA is 25% of salary and DA is 10% of salary. PF is 5% of salary. The result should
be in descending order of salary.
29. If the file 'poemBTH.txt' contains the following poem (by Paramhans Yoganand):
God made the Earth;
Man-made confining countries
And their fancy-frozen boundaries.
But with unfound boundless Love
I behold the borderland of my India
Expanding into the World.
Hail, mother of religions, Lotus, scenic beauty and sages!
What outputs will be produced by both the code fragments given below:

Copyright © myCBSEguide.com. Mass distribution in any mode is strictly prohibited.


4 / 12
myCBSEguide
a. my_file =open('poemBTH.txt', 'r')
my_file.read()
b. my_file = open('poemBTH.txt', 'r')
my_file.read(100)
30. From the program code given below, identify the parts mentioned below :
1. def processNumber(x):
2. x = 72
3. return x + 3
4.
5. y = 54
6. res = processNumber(y)
Identify these parts: function header, function call, arguments, parameters, function body, main program.
Section D

31.

Consider a dictionary with keys as course name and fee as value. Write a program to push course name in stack where fee is more than 10000. Pop and display contents of
stack on the screen
i) Write a code to add the fee and course name to course_dict.
ii) Complete the code to compare the fee of the given key(course).
iii) Write a code to insert the element in the Stack.
iv) Write a code to find the length of the Stack.
32. Consider the following tables ACTIVITY and COACH. Write SQL commands for the following statements

Table: ACTIVITY

Acode ActivityName Stadium ParticipantsNum PrizeMoney ScheduleDate

1001 Relay 100 × 4 Star Annex 16 10000 23-Jan-04

1002 High jump Star Annex 10 12000 12-Dec-03


1003 Shot Put Super Power 12 8000 14-Feb-04

1005 Long Jump Star Annex 12 9000 01-Jan-04

1008 Discuss Throw Super Power 10 15000 19-Mar-04

Table: COACH

Pcode Name Acode

1 Ahmad Hussain 1001

2 Ravinder 1008
3 Janila 1001

4 Naaz 1003
i. To display the names of all activities with their Acodes in descending order.
ii. To display sum of PrizeMoney for the Activities played in each of the Stadium separately.
iii. To display the coach's names and Acodes in ascending order of Acode from the table COACH.
iv. To display the content of all activities for which ScheduleDate is earlier than 01-01-2004 in ascending order of ParticipantsNum.

Copyright © myCBSEguide.com. Mass distribution in any mode is strictly prohibited.


5 / 12
myCBSEguide
Section E
33. Freshminds University of India is starting its first campus in Anna Nagar of South India with its centre admission office in Kolkata. The university has three major blocks
comprising of Office block, Science block and Commerce block is in 5 km area campus.
As a network expert, you need to suggest the network plan as per (i) to (v) to the authorities keeping in mind the distance and other given parameters.

Expected wire distance between various locations

Office Block to Science Block 90 m

Office Block to Commerce Block 80 m


Science Block to Commerce Block 15 m

Kolkata Admission Office to Anna Nagar Campus 450 km

Expected number of computers to be installed at various locations in the university are as follows:

Office Block 10
Science Block 140

Commerce Block 30

Kolkata Admission Office 8


i. Suggest the authorities, the cable layout amongst various blocks inside university campus for connecting the blocks.
ii. Suggest the most suitable place (i.e. block) to house the server for this university with a suitable reason.
iii. Suggest an efficient device form the following to be installed in each of the block to connect all the computers.
a. Modem
b. Switch
c. Gateway
iv. Suggest the most suitable (very high speed) service to provide data connectivity between admission office located in Kolkata and the campus located in Anna Nagar
form the following options:
Telephone line
Fixedline dial-up connection
Co-axial cable network
GSM
Leased line
Satellite connection.
v. University is planning to connect its campus in Kolkata which is more than 100 km. Which type of network will be formed?
34. Write SQL queries for (i) to (vii) on the basis of table ITEMS and TRADERS:

Table: ITEMS

ICODE INAME QTY PRICE COMPANY TCODE

1001 DIGITAL PAD 12i 120 11000 XENITA T01

1006 LED SCREEN 40 70 38000 SANTORA T02

1004 CAR GPS SYSTEM 50 21500 GEOKNOW T01

1003 DIGITAL CAMERA 12X 160 8000 DIGICLICK T02

1005 PEN DRIVE 32 GB 600 1200 STOREHOME T03

Table: TRADERS

TCode TName City

101 ELECTRONIC SALES MUMBAI

103 BUSY STORE CORP DELHI

102 DISP HOUSE INC CHENNAI


i. To display the details of all the items in ascending order of item names (i.e., INAME).

Copyright © myCBSEguide.com. Mass distribution in any mode is strictly prohibited.


6 / 12
myCBSEguide
ii. To display item name and price of all those items, whose price is in the range of 10000 and 22000 (both values inclusive).
iii. To display the number of items, which are traded by each trader. The expected output of this query should be:
T01 2 T02 2 T03 1
iv. To display the price, item name and quantity (i.e., qty) of those items which have quantity more than 150.

OR

Consider the following tables STOCK and DEALERS and answer (a) and (b) parts of this question:

Table: STOCK

ItemNo Item Dcode Qty UnitPrice StockDate

5005 Ball Pen 0.5 102 100 16 31-Mar-10

5003 Ball Pen 0.25 102 150 20 01-Jan-10


5002 Gel Pen Premium 101 125 14 14-Feb-10

5006 Gel Pen Classic 101 200 22 01-Jan-09

5001 Eraser Small 102 210 5 19-Mar-09

5004 Eraser Big 102 60 10 12-Dec-09

5009 Sharpener Classic 103 160 8 23-Jan-09

Table: DEALERS

Dcode Dname

101 Reliable Stationers


103 Classic Plastics

102 Clear Deals


a. Write SQL commands for the following statements:
i. To display the details of all Items in the STOCK table in ascending order of StockDate.
ii. To display ItemNo and Item name of those items from STOCK table whose UnitPrice is more than Rupees 10.
iii. To display the details of those items whose dealer code (Dcode) is 102 or quantity in STOCK (Qty) is more than 100 from the table Stock.
iv. To display maximum UnitPrice of items for each dealer individually as per Dcode from the table STOCK.
b. Give the output of the following SQL queries:
i. SELECT COUNT (DISTINCT Dcode) FROM STOCK;
ii. SELECT Qty* UnitPrice FROM STOCK WHERE ItemNo=5006;
iii. SELECT Item, Dname FROM STOCK S, Dealers D WHERE S.Dcode=D.Dcode AND ItemNo = 5004;
iv. SELECT MIN (StockDate) FROM STOCK;
35. Answer:
1. i. Give the SQL statement to create a table Student with Roll Number, Name, Age and Marks.
ii. Give output for following SQL queries as per given table(s) :

relation Teacher

No. Name Age Department Date of join Salary Sex

1. Jugal 34 Computer 10/01/97 12000 M


2. Sharmila 31 History 24/03/98 20000 F

3. Sandeep 32 Maths 12/12/96 30000 M

4. Sangeeta 35 History 01/07/99 40000 F

5. Rakesh 42 Maths 05/09/97 25000 M

6. Shyam 50 History 27/06/98 30000 M

7. Shiv Om 44 Computer 25/02/97 21000 M

8. Shalakha 33 Maths 31/07/97 20000 F


i. SELECT COUNT (distinct department) FROM TEACHER;
ii. SELECT MAX (Age) FROM TEACHER WHERE Sex = "F";
iii. SELECT AVG(Salary) FROM TEACHER WHERE Dateofjoin< {12/07/96};
iv. SELECT SUM (Salary) FROM TEACHER WHERE Dateofjoin < {12/07/96}
2. OR
i. Write a query on the customer table that will find the highest rating in each city. Put the output in this form: For the city (city), the highest rating is: (rating).
ii. Consider the following table GAMES. Write SQL commands for the following statements.

Table: GAMES

Copyright © myCBSEguide.com. Mass distribution in any mode is strictly prohibited.


7 / 12
myCBSEguide
GCode GameName Type Number PrizeMoney ScheduleDate

101 Carom Board Indoor 2 5000 23-Jan-2004

102 Badminton Outdoor 2 12000 12-Dec-2003

103 Table Tennis Indoor 4 8000 14-Feb-2004

105 Chess Indoor 2 9000 01-Jan-2004

108 Lawn Tennis Outdoor 4 25000 19-Mar-2004


i. To display the name of all GAMES with their GCodes.
ii. To display details of those GAMES which are having PrizeMoney more than 7000.
iii. To display the content of the GAMES table in ascending order of ScheduleDate.
iv. To display sum of PrizeMoney for each Type of GAMES.

To practice more questions & prepare well for exams, download myCBSEguide App. It provides complete study material for CBSE, NCERT, JEE (main),
NEET-UG and NDA exams. Teachers can use Examin8 App to create similar papers with their own name and logo.

Copyright © myCBSEguide.com. Mass distribution in any mode is strictly prohibited.


8 / 12
myCBSEguide

Class 12 - Computer Science


Sample Paper - 01 (2023-24)

Solution

Section A
1. (b) False
Explanation: False
2. (d) DML (Data Manipulation Language)
Explanation: DML (Data Manipulation Language) performs the change in the values of the relation.
3. (a) s.__getitem__(i)
Explanation: It is the correct syntax to call character at index i of string s
4. (d) A global variable
Explanation: A global variable
5. (d) analog signal
Explanation: Analog Signal, a continuous time varying signal, which represents a time varying quantity.
6. (a) fout = open("c:\ \pat.txt", "wb+")
Explanation: fout = open("c:\ \pat.txt", "wb+")
7. (a) Relational Algebra
Explanation: All others are non procedural language.
8. (d) Relations
Explanation: Fields are the column of the relations
9. (c) a, c
Explanation: (a) and (c) statements have the correct syntax to open the file in append mode.
10. (d) program
Explanation: program
11. (b) Top
Explanation: The top is the pointer variable that contains the first or topmost element of the stack.
12. (c) 25*50!100!25
Explanation: 25*50!100!25
13. (a) True
Explanation: True, SSL provides a mechanism for encrypting and authenticating data sent between processes running on a client and server, as well as mediating
the secure exchange of private keys for session encryption through the use of an SSL certificate issued by a trusted certificate authority.
14. (b) True
Explanation: True
15. 1. WHERE
16. (d) A system designed to prevent unauthorized access.
Explanation: A firewall is a network security device that monitors incoming and outgoing network traffic and decides whether to allow or block specific traffic based on a
defined set of security rules.
17. (d) A is false but R is true.
Explanation: We can say that Python is a cross platform language as Python can run on different platforms such as Windows, Linux, UNIX, and Macintosh, etc. It enables
programmers to develop the software for several computing platforms by writing a program only once.
18. (a) Both A and R are true and R is the correct explanation of A.
Explanation: After closing the file, we cannot perform any operation in the file. The file needs to be properly closed. If any exception occurs while performing some
operation in the file then the program terminates without closing the file.
Section B
19. Answer:
1. i. Guided media is a point to point communication to connect computers, it uses cables, whereas unguided media is a wireless communication which transmits
the signal through the air.
ii. In-circuit switching, a dedicated path exists from source to destination while in packet switching, there is no fixed path.
2. OR
i. Modulation is the technique of changing the characteristics of the signal being transmitted so that it carries data and Demodulation is the reverse process of
modulation where data is extracted from the received signal (i.e., from the modulated wave). Another crucial difference between modulation and demodulation
is that modulation is done at the transmitting end while demodulation occurs at the receiving end.
20. import MySQLdb
db=MySQLdb.connect('localhost', 'sales', 'Admin', 'salar345')
cursor= db. cursor (prepared= TRUE)
sql_query= """INSERT INTO order-details (ORDNUMB, PARTNUMB, NUMBORD,QUOTPRIC) VALUES ('%s', '%s', '%s','%s')"""
rec_inst= [('12489', 'AX12', '11','14.95'), ('12491', 'ABT04', '1','402.99'), ('12495', 'BZ66', '1','311.95'),
('12498', 'CX11', '2','57.95')]
try:
cursor. executemany(sql_query, rec_inst)
print(cursor.rowcount, "Record inserted successfully")

Copyright © myCBSEguide.com. Mass distribution in any mode is strictly prohibited.


9 / 12
myCBSEguide
db.commit()
except:
db.rollback()
cursor.close()
db.close()

21. False Boolean

'True' String

"False" String

45345 Integer

0O434 Integer (octal)

435.3 Floating point

OR

x = input ('Enter value of x : ')


y = input ('Enter value of y : ')
print (" After swapping")
#create a temporary variable and swap the values
temp = x
x = y
y = temp
print ('The value of x :', x)
print ('The value of y : ', y)

Output
Enter value of x : 75
Enter value of y : 70
After swapping
The value of x : 70
The value of y : 75
22. Answer:
1. fetchone() method returns the next row from the result set as tuple while fetchall() fetches all the rows of a query result.
2. 'Ushakiran', 42568987036
23. i. List
ii. String

OR

To access the tuple’s elements, index number is used. Use the index operator [ ], elements of a tuple can be accessed. The index should be an integer. Index of 0 refers to
first element, 1 refers to second element and so on. While the index of - 1 refers to the last element, - 2 refers to the second last element and soon.
e.g. t1 = (87, 90, ‘Maths’, ‘English’, 56, 44, 99, ‘Science’, 23)

24. fileObject = open("Article.txt",r)


count = 0
str = fileObject.read()
for char in str:
if char.isupper():
count += 1
fileObject.close()
print ("Number of uppercase characters are ", count)

OR

Statement1 uses seek() method that can be used to position the file object at particular place in the file. It’s syntax is:

FileObject.seek(offset[, from_what])

So, f.seek(-3, 2) positions the FileObject to 3 bytes before end of file.


Output of statement2: de
25. Fruitful function - The functions that return a value i.e., non-void functions are also known as fruitful functions.
Non - fruitful function - The functions that do not return a value, i.e., void functions are also known as non-fruitful functions.

Copyright © myCBSEguide.com. Mass distribution in any mode is strictly prohibited.


10 / 12
myCBSEguide
Section C
26. Answer:
1. dic = { }
dic[‘A’] = 'One'
dic[‘ B’] = 'Two'
dic[‘C’] = 'Three'
dic[‘D’] = 'Four’
2. Hello World
26
20202020
HelloHello
HelloWorld20
27. These are the outputs to the above code segments:
i. 1
1
1
ii. 1
10
1
iii. 1
10
10
iv. Hello there!
28. Primary Key: A column or set of columns that uniquely identifies a row within a table is called a primary key.
For example, in the following table Student, the column Roll no. can uniquely identify each row in the table, hence Roll no. is the primary key of the following table.
Roll no. Name Marks Grade

1 - - -

2 - - -

3 - - -

4 - - -

OR

SELECT E_Name, SALARY, SALARY * 0.25


AS HRA, SALARY*0.10
AS DA, SALARY*0.05 AS PF
FROM EMPLOYEE
ORDER BY SALARY DESC;

29. i. my_file =open('poemBTH.txt', 'r') will open the given file in read mode and my_file.read() read the entire file in string form.
ii. my_file = open('poemBTH.txt', 'r') will open the given file in read mode and my_file.read(100) read only the first 100 bytes from the file and store the read bytes in
form of a string.

30. Function header def processNumber(x) : in line 1

Function call processNumber (y) in line 6

Arguments y in line 6

Parameters x in line 1
x = 72
Function body in lines 2 and 3
return x + 3
y = 54
Main program in lines 5 and 6
res = processNumber(y)
Section D
31. i) course_dict[course] = fee
ii) course_dict[key]
iii) append(key)
iv) len(STACK)
32. i. SELECT Acode, ActivityName FROM ACTIVITY ORDER BY Acode DESC;
ii. SELECT Stadium, SUM(PrizeMoney) FROM ACTIVITY GROUP BY Stadium;
iii. SELECT Name, Acode FROM COACH ORDER By Acode;
iv. SELECT * FROM ACTIVITY WHERE SchduleDate < '01-Jan-2004' ORDER BY ParticipantsNum;
Section E

Copyright © myCBSEguide.com. Mass distribution in any mode is strictly prohibited.


11 / 12
myCBSEguide

33. i.

ii. The most suitable place to house the server is Science Block as it has maximum number of computers. Thus, reducing the cabling cost and increases efficiency of
network.
iii. (b) Switch is the device to be installed in each of the blocks to connect all the computers.
iv. Satellite connection
v. MAN
34. i. SELECT * FROM ITEMS ORDER BY INAME ASC;
ii. SELECT INAME, PRICE FROM ITEMS WHERE PRICE = > 10000 AND PRICE = < 22000;
iii. SELECT TCODE, COUNT (CODE) FROM ITEMS GROUP BY TCODE;
iv. SELECT PRICE, INAME, QTY FROM ITEMS WHERE QTY > 150

OR

a. i. SELECT * FROM STOCK ORDER BY StockDate ;


ii. SELECT ItemNo , Item FROM STOCK WHERE UnitPrice >10 ;
iii. SELECT * FROM DEALERS, STOCK WHERE (DEALERS.Dcode="102" OR STOCK.Qty >100 and DEALERS. DCODE = STOCK.DCODE);
iv. SELECT MAX (Unitprice) FROM DEALERS, STOCK ORDER BY STOCK. Dcode WHERE DEALERS.Dcode = STOCK.Dcode;
b. i. 3
ii. 4400

iii. Item Dname


Eraser Big Clear Deals
iv. 01-jun-09
35. Answer:

1. i. CREATE TABLE Student (Roll_Number NUMBER(5) Primary key, Name CHAR (20), Age Number (2), Marks Number (4));

ii. OUTPUT
i. 3
ii. 35
iii. 0
iv. 0
2. OR
i. SELECT city, 'the highest rating is MAX (rating) FROM customer GROUP BY city ;

ii. i. SELECT GCode, GameName FROM GAMES ;


ii. SELECT * FROM GAMES WHERE PrizeMoney > 7000 ;
iii. SELECT * FROM GAMES ORDER BY ScheduleDate ;
iv. SELECT SUM(PrizeMoney), Type FROM GAMES GROUP BY Type ;

To practice more questions & prepare well for exams, download myCBSEguide App. It provides complete study material for CBSE, NCERT, JEE (main),
NEET-UG and NDA exams. Teachers can use Examin8 App to create similar papers with their own name and logo.

Copyright © myCBSEguide.com. Mass distribution in any mode is strictly prohibited.


12 / 12

You might also like