Advertisement
TheDemarti

Classe Medico

Jul 8th, 2018
110
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.41 KB | None | 0 0
  1. class medico:
  2.   def __init__(self, nome, spec):
  3.     # @param n: string
  4.     # @param spec: string
  5.     # @param colleghi: list
  6.     self.n = nome
  7.     self.s = spec
  8.     self.c = []
  9.    
  10.   def nome(self):
  11.     return self.n
  12.  
  13.   def spec(self):
  14.     return self.s
  15.  
  16.   def colleghi(self):
  17.     return self.c
  18.    
  19.   def newCol(self, coll):
  20.   # @param coll: string
  21.     self.c += [coll.nome(), coll.spec()]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement