18 solutions available
Question 7Find errors (if any) in the following code and rewrite the code underlining each correction:x = int("Enter value of x:") for in range[0,...
Question 12What is the use of "w" in file handling?
Question 13Rewrite the following SQL statement after correcting the error(s). Underline the corrections made.INSERT IN STUDENT (RNO, MARKS) VALUE...
Question 14Write a function Push() which takes number as argument and add in a stack "MyValue".SolutionMyValue = [] def Push(number):...
Question 15Write the output of the following code:for i in range(5): print(i)
Question 16Expand the following:(a) LIFO(b) FIFO
Question 17Assertion (A): Program should check for Overflow condition before executing Push operation on stack and similarly check for Underflow...
Question 18Assertion (A): ('x' and 'y' or not 7) is a valid expression in Python.Reason (R): In Python, strings and numbers can be treated as Boolean...
Question 20Write push(rollno) and pop() method in Python:push(rollno) — to add roll number in Stackpop() — to remove roll number from...
Question 21Write the output of the following code with justification if the contents of the file "VIVO.txt" are:"Welcome to Python Programming!"F1 =...
Question 23(a)Given is a Python string declaration:voice = "Python for All Learners"Write the output of:print(voice[20 : : -2])
Question 23(b)Write the output of the code given below:d1 = {"A" : "Avocado", "B" : "Banana"} d2 = {'B' : 'Bag', 'C' : 'Couch'} d2.update(d1)...
Question 24What will the following snippet print?L5 = [1500, 1800, 1600, 1200, 1900] begin = 1 sum = 0 for c in range(begin, 4): sum = sum +...
Question 25Consider the following two SQL commands with reference to a table, named MOVIES, having a column named Director:(a) Select Distinct...
Question 27In a database BANK, there are two tables with a sample data given below:Table:...
Question 28(b)Write a function reverseFile() in Python to read lines from text file 'TESTFILE.TXT' and display the file content in reverse order so...
Question 31A departmental store "ABC" is considering maintaining their inventory using SQL to store data and maintain basic transactions. As a...
Question 34(b)The code given below accepts the roll number of a student and deletes the record of that student from the table STUDENT. The structure...