Skip to content

Instantly share code, notes, and snippets.

@blast-hardcheese
Created August 11, 2013 02:14
Show Gist options
  • Save blast-hardcheese/6203088 to your computer and use it in GitHub Desktop.
Save blast-hardcheese/6203088 to your computer and use it in GitHub Desktop.
class Email:
name = None
email = None
def __init__(self, name, email):
self.name = name
self.email = email
def __str__(self):
return "%s <%s>" % (self.name, self.email)
def __repr__(self):
return "Email(%s, %s)" % (repr(self.name), repr(self.email))
email = Email("Devon Stewart", "blast@hardchee.se")
print "%s vs %r" % (email, email)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment