Advertisement
Guest User

Untitled

a guest
Aug 19th, 2017
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.54 KB | None | 0 0
  1. # I think that I don't quite understand the instrunction as it seems too simple
  2.  
  3. class Message:
  4.     pass # implementation
  5.  
  6.  
  7. class Person:
  8.     pass # implementation
  9.  
  10.  
  11. class Phone(object):
  12.  
  13.     def __init__(self, message, person):
  14.         self.message = message
  15.         self.person = person
  16.  
  17.     def send_message(self):
  18.         self.open_connection(self.person)
  19.         self.write_connection(self.message)
  20.         self.close_connection()
  21.  
  22. message = Message()
  23. person = Person()
  24. phone = Phone(message, person)
  25. phone.send_message()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement