QUIZ ON : PROGRAMMING AND PROBLEM SOLVING THROUGH PYTHON - MODULES

MODULES

00:00:00

FTP is a _____?

Option A. Stateful protocol
Option B. Stateless protocol
Option C. Both
Option D. None
True Answer A

Explanation :

FTP is a _____?

Question No# : 01 out of 20



Which type of error are flagged by compilers

Option A. Logical errors
Option B. Syntax errors
Option C. Both Logical and Syntax errors
Option D. None of these
True Answer B

Explanation :

Which type of error are flagged by compilers

Question No# : 02 out of 20



A function is a piece of code that can be used from elsewhere in a sketch

Option A. TRUE
Option B. FALSE
Option C.
Option D.
True Answer A

Explanation :

A function is a piece of code that can be used from elsewhere in a sketch

Question No# : 03 out of 20



What will be the output of the following Python code

import sys

sys.argv

Option A. ‘ ‘
Option B. [ ]
Option C. [‘ ‘]
Option D. Error
True Answer C

Explanation :
The output of the code shown above is a blank space inserted in single quotes, which is enclosed by square brackets. Hence the output will be [‘ ‘].

What will be the output of the following Python code

import sys

sys.argv

Question No# : 04 out of 20



Choose the statement where underlined word is used correctly.

Option A. The industrialist had a persnnel jet.
Option B. I write my experience in my persannel diary
Option C. All personnel are being given the day off.
Option D. Being religious is a personnal aspect.
True Answer C

Explanation :
All personnel are being given the day off.

Choose the statement where underlined word is used correctly.

Question No# : 05 out of 20



Printers can be classified by the method of their printing

Option A. TRUE
Option B. FALSE
Option C.
Option D.
True Answer A

Explanation :

Printers can be classified by the method of their printing

Question No# : 06 out of 20



The length of the path from v5 to v6 in the MST of previous question with n = 10 is

 

An undirected graph G(V,E) contains n (n > 2) nodes named  Two nodes vivj are connected if and only if  Each edge  is assigned a weight i + j. A sample graph with n = 4 is shown below.

Option A. 11
Option B. 25
Option C. 31
Option D. 41
True Answer C

Explanation :

 

The length of the path from v5 to v6 in the MST of previous question with n = 10 is

 

An undirected graph G(V,E) contains n (n > 2) nodes named  Two nodes vivj are connected if and only if  Each edge  is assigned a weight i + j. A sample graph with n = 4 is shown below.

Question No# : 07 out of 20



Consider a hash table with 9 slots. The hash function is ℎ(k) = k mod 9. The collisions are resolved by chaining. The following 9 keys are inserted in the order: 5, 28, 19, 15, 20, 33, 12, 17 and 10. The maximum, minimum, and average chain lengths in the hash table, respectively, are

Option A. 3, 0, and 1
Option B. 3, 3, and 3
Option C. 4, 0, and 1
Option D. 3, 0, and 2
True Answer A

Explanation :

 

Therefore, the maximum and minimum chain length is 3 & 0 respectively.
Average chain length = (0 + 3 + 1 + 1 + 0 + 1 + 2 + 0 + 1)/9 = 1.

Consider a hash table with 9 slots. The hash function is ℎ(k) = k mod 9. The collisions are resolved by chaining. The following 9 keys are inserted in the order: 5, 28, 19, 15, 20, 33, 12, 17 and 10. The maximum, minimum, and average chain lengths in the hash table, respectively, are

Question No# : 08 out of 20



The default port for SMTP is:

Option A. 21
Option B. 23
Option C. 25
Option D. 80
True Answer C

Explanation :

The default port for SMTP is:

Question No# : 09 out of 20



In which topology,entire network gets shut down if Hub is damaged?

Option A. Ring topology
Option B. Bus topology
Option C. Star topology
Option D. Mesh topology
True Answer C

Explanation :

In which topology,entire network gets shut down if Hub is damaged?

Question No# : 10 out of 20



Binet-Simon tests measure

Option A. General intelligence
Option B. Specific intelligence
Option C. Attitude
Option D. Aptitude
True Answer A

Explanation :
The Stanford-Binet intelligence Scale is an individually administered General intelligence test that was revised from the original Binet-Simon Scale by Lewis M Terman, a psychologist at Stanford University.It is a cognitive ability and intelligence test that is used to diagnose developmental or intellectual deficiencies in young children.

Binet-Simon tests measure

Question No# : 11 out of 20



What is full form of UPS?

Option A. United parcel service
Option B. Uniform product support
Option C. Under Power Supply
Option D. Uninterrupted power supply
True Answer D

Explanation :

What is full form of UPS?

Question No# : 12 out of 20



What will be the value of mod (50, -7)?

Option A. 6
Option B. -6
Option C. 1
Option D. -1
True Answer B

Explanation :

What will be the value of mod (50, -7)?

Question No# : 13 out of 20



What will be the output of the following Python code?

print("abcdef".find("cd"))

Option A. True
Option B. 2
Option C. 3
Option D. None of the mentioned
True Answer B

Explanation :
The first position in the given string at which the substring can be found is returned.

What will be the output of the following Python code?

print("abcdef".find("cd"))

Question No# : 14 out of 20



A symmetric diagraph is a directed graph such that for every edge VW there is reverse edge WV.

Option A. TRUE
Option B. FALSE
Option C.
Option D.
True Answer A

Explanation :

A symmetric diagraph is a directed graph such that for every edge VW there is reverse edge WV.

Question No# : 15 out of 20



Consider a complete binary tree where the left and the right subtrees of the root are max-heaps. The lower bound for the number of operations to convert the tree to a heap is

Option A. Ω (log n)
Option B. Ω (n)
Option C. Ω (n log n)
Option D. Ω (n2)
True Answer A

Explanation :

 The answer to this question is simply max-heapify function. Time complexity of max-heapify is O(Log n) as it recourses at most through height of heap.
// A recursive method to heapify a sub tree with root at given index
// this method assumes that the sub trees are already heapified
Void MinHeap::MaxHeapify(int i)
{
Int l = left(i);
Int r = right(i);
Int largest = i;
If (l < heap size && harr[l] < harr[i])
Largest = l;
If (r < heap size && harr[r] < harr[smallest])
Largest = r;
If (largest != i)
{
Swap(&harr[i], &harr[largest]);
MinHeapify(largest);
}
}

Consider a complete binary tree where the left and the right subtrees of the root are max-heaps. The lower bound for the number of operations to convert the tree to a heap is

Question No# : 16 out of 20



That which cannot be read.

Direction: In the following question, out of the four alternatives, choose the one which can be substituted for the given words/ sentence.

Option A. Incorrigible
Option B. Illegible
Option C. Eligible
Option D. Illiterate
True Answer B

Explanation :
Illegible means which cannot be read or is not clear enough to be read. Incorrigible means that which cannot be corrected. Eligible means having the right to do or obtain something; satisfying the appropriate conditions. Illiterate means someone who is unable to read or write.

That which cannot be read.

Direction: In the following question, out of the four alternatives, choose the one which can be substituted for the given words/ sentence.

Question No# : 17 out of 20



The keyword used to transfer control from a function back to the calling function is

Option A. switch
Option B. goto
Option C. go back
Option D. return
True Answer D

Explanation :

The keyword used to transfer control from a function back to the calling function is

Question No# : 18 out of 20



Which built-in method returns the character at the specified index?

Option A. characterAt()
Option B. getCharAt()
Option C. charAt()
Option D. None of the above
True Answer C

Explanation :

Which built-in method returns the character at the specified index?

Question No# : 19 out of 20

What cannot be done from windows control panel?

Option A. Run Application
Option B. Printer configuration
Option C. Add fonts
Option D. Install Application
True Answer A

Explanation :

What cannot be done from windows control panel?

Question No# : 20 out of 20




CCC Online Test 2021 CCC Practice Test Hindi Python Programming Tutorials Best Computer Training Institute in Prayagraj (Allahabad) Best Java Training Institute in Prayagraj (Allahabad) Best Python Training Institute in Prayagraj (Allahabad) O Level NIELIT Study material and Quiz Bank SSC Railway TET UPTET Question Bank career counselling in allahabad Sarkari Naukari Notification Best Website and Software Company in Allahabad Website development Company in Allahabad