NPTEL » Programming, Data Structures And Algorithms Using Python

Week 6 Quiz

Due date: 2019-09-11, 23:59 IST.
Your last recorded submission was on 2019-09-11, 15:49 IST
All questions carry equal weightage. All Python code is assumed to be executed using Python3. You may submit as many times as you like within the deadline. Your final submission will be graded.
Note:
  • If the question asks about a value of type string, remember to enclose your answer in single or double quotes.
  • If the question asks about a value of type list, remember to enclose your answer in square brackets and use commas to separate list items.
2.5 points
Suppose u and v both denote sets in Python. Under what condition can we guarantee that u - (u - v) == v?
 
 
 
 
2.5 points
Suppose u and v both denote sets in Python. Under what condition can we guarantee that u|v == u^v?
 
 
 
 
Suppose we insert 97 into the max heap [98,67,89,38,42,54,89,17,25]. What is the resulting heap?
[98,97,89,38,67,54,89,17,25,42]
2.5 points
Suppose we we apply delete_max() twice to the heap [100,97,93,38,67,54,93,17,25,42].  What is the resulting heap?
[93,67,93,38,42,54,25,17]

1 comment

File Uploading in PHP

  File Uploading in PHP PHP allow you to upload any type of a file i.e. image, binary or text files.etc..,PHP has one in built global variab...