Skip to content

Instantly share code, notes, and snippets.

@jonascheng
Created June 8, 2019 14:53
Show Gist options
  • Save jonascheng/b65aafa0d447d62d590c4554d6f3bfe2 to your computer and use it in GitHub Desktop.
Save jonascheng/b65aafa0d447d62d590c4554d6f3bfe2 to your computer and use it in GitHub Desktop.
SOLID-EmployeeClassWithPrintMethods
import datetime
class Employee:
// ...
def printForHR(self):
print(u'{},{},{}'.format(self.first_name, self.last_name, self.wage))
def printForIT(self):
print(u'{},{},{}'.format(self.first_name, self.last_name, self.birth))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment