Computer
Computer
(f) Write the Python code to create the dictionary to include the list of following countries
and their capital. 2
(b)Given the following code , write down what would be printed as output- 1
A=3
While(I in a):
Print “”Happy”**i
(c) Write pseudo-code / flowchart to input the year and to test and display whether the given
year is leap year or not? 3
(d)Write python program to calculate area of circle. The radius being the input. 2
(e)Given the following python code what values are printed as output? 2
def afunc(B):
B=B%2
Print B
A=2
afunc(A)
afunc(A+5)
Print A
(a)What is the function performed by len() and reverse() in the list module. 2
(b) Find error in the given SQL code: (Consider the table: ADM ) 1
b) What is Cracking? Suggest the ways to protect the computer from cyber attack. 2
(i) Write the SQL command to create the above table with constraints. 1
(v) Change the Stream of Student to ‘Computer’ Whose Roll no. is 536. 1
(vi) Add one column email of data type VARCHAR and size 30 to the table student. 1
(b) To list the names of female patients who are in ENT department. 1
(c) To list names of all patients with their date of admission in ascending order. 1
(d) To display Patient’s Name, Charges, Age for only female patients. 1
a=[1,2,3]
b=[4,5,6]
c=a*b
d=c[0:3]
e=d
a[5]=10
c[1]=20
e[0]=30
(i) Print e (ii) print a (iii) print d (iv) print c
e) Write a python program to receive the numbers from user through keyboard until user
gives 0 (to end the input process), then the program calculate and display the sum of given
odd numbers and even numbers respectively.
[4]
e.g.
7 5 10 143 911 12