## Week 3 | Programming Assignment | Programming, Data Structures and Algorithms using Python | Apr 2018

Download Python File:- Raw File | Download (Please rename it to .py file once downloaded, for it to run) def alternating(l): if (len(l) > 1): if l[0] > l[1]: for i in range(len(l) – 1): if l[i] == l[i – 1]: return False if i % 2 == 0: if l[i] < Read more…

## Week 2 Quiz | Programming, Data Structures And Algorithms Using Python | Apr 2018

UPDATE TO ANSWER OF QUESTION 1 : PLEASE CHECK 1) One of the following 10 statements generates an error. Which one? (Your answer should be a number between 1 and 10.) x = [[7,8],3,”hello”,[6,8],”world”,17] # Line 1 z = [x[0],x[3]] # Line 2 y = x[0:50] # Line 3 w Read more…

## Week 2 Quiz Answers revised | Introduction to Modern Application Development | Apr 2018

ANSWER TO QUESTION 7 UPDATED. PLEASE CHECK 1) Which of the following is/are valid HTTP request methods a) POST b) SEND c) RECEIVE d) GET Answer(s) : POST, GET 2) Which of the following statements are incorrect: a) localhost needs a DNS lookup while 127.0.0.1 does not b) 127.0.0.1 requires Read more…

## Week 1 Quiz | Introduction to Modern Application Development | Apr 2018

1) Which of the following statements are true: a) A webapp is a software that lets you access websites b) A webapp is defined as a software that can be downloaded from the web c) A webapp is a tool which helps us build websites d) A webapp is a Read more…

## Week 2 Programming Assignment | NPTEL Programming, Data Structures and Algorithms using Python | Apr 2018

Questions :- A positive integer m is a sum of squares if it can be written as k + l where k > 0, l > 0 and both k and l are perfect squares.Write a Python function sumofsquares(m) that takes an integer m returns True if m is a Read more…

## Week 1 Quiz | Programming, Data Structures And Algorithms Using Python | Apr 2018

1) What does f(31415927) return, for the following function definition? def f(x): d=0 while x > 1: (x,d) = (x/2,d+1) return(d) Answer(s) : 25 [quads id=1] 2) What is the value of h(6,8) for the function below? def h(m,n): ans = 1 while (n > 0): (ans,n) = (ans*m,n-2) return(ans) Read more…

## NPTEL Solutions (Jan-Apr 2018)

Here you can find all the solution of all courses of NPTEL  Computer Science stream. We hope this will be useful to you. These answers are for verification only. You are not allowed to copy directly from the post. We ensure that you can get 100% marks if you follow our Read more…

## Solution for NPTEL, Introduction to Modern Application Development(IMAD) Week 7 MCQs

1) The “git reset –soft ” command: a) Adds a commit which undoes all file changes made in <commit-id> b) Add a commit which undoes all file changes since <commit-id> c) Removes all commits and file changes since <commit-id> d) Removes all commits since <commit-id> but keeps the changes in Read more…

## Solution for NPTEL Programming, Data Structures and Algorithms using Python, Week 8 Programming Assignment

Question :- Find the longest palindrome As we all know, a palindrome is a word that equals its reverse. Here are some examples of palindromes: malayalam, gag, appa, amma. [quads id=1] We consider any sequence consisting of the letters of the English alphabet to be a word. So axxb,abbba and bbbccddx are words for our Read more…

## ONLINE TEST 2-5 PM | Solution for NPTEL Programming, Data Structures and Algorithms using Python

All answers have been verified. Question – 1 :- Here is an function to return the maximum value in a list of integers. There is an error in this function. Provide an input list for whichmaxbad produces an incorrect output. def maxbad(l):   mymax = 0   for i in range(len(l)):     if l[i] > mymax:        mymax = l[i]   return(mymax) Answer:- [-3,-2,-1] [quads id=1] Question Read more…