Question: given is a code snippet in python : import sys class mammal : def _init_(self) : self.legs = 4 self.face = (2,2,1) def speak (self)

given is a code snippet in python :

import sys

class mammal :

def _init_(self) :

self.legs = 4

self.face = (2,2,1)

def speak (self) :

pass

class dog (mammal) :

def speak (self) :

print "I bark"

class cat (mammal) :

def speak (self) :

print "I purr"

class pig (mammal) :

def speak (self) :

print "I grunt"

class tiger (cat) :

def speak (self) :

print "I roar"

class man (dog,cat,pig,tiger) :

pass

___________________________

Question - modify the code such that man will have 2 ears, 2 eyes, 1 nose, 2 legs, 2 hands and is able to speak like other mammals as well as should talk, i.e, Man should speak : I bark I purr I grunt I roar I even talk.

PLEASE INCLUDE ALL THE STEPS AND EXPLAIN THE ANSWER IN DETAIL

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!