B01E-2015D – Computer Sir Ki Class

Login


Lost your password?

Don't have an account ?
Register (It's FREE) ×
  

Login
[lwa]



Exam Questions-CBSE12D-2015-B01E #PYTHON#6514    siteicon   siteicon  

Problem Statement - B01E-2015D

Find and write the output of the following python code:

class Worker :
    def_init_(self,id,name): #constructor
        self.ID=id
        self.NAME=name
    def Change (self) :
        self.ID=self.ID+10
        self.NAME='Harish'
    def Display(self,ROW) :
        print self.ID,self.NAME,ROW
w=Worker(55,'Fardeen')
w.Display(l)
w.Change( )
w.Display(2)
print w.ID+len(w.NAME)

Solution

TC++ #6514

55 Fardeen 1
65 Harish 2
71


Share

CSKC| Created: 12-Jan-2019 | Updated: 12-Jan-2019|CBSE12D-2015









Back