Skip to content

Instantly share code, notes, and snippets.

@gumeniukcom
Created November 22, 2011 18:12
Show Gist options
  • Save gumeniukcom/1386401 to your computer and use it in GitHub Desktop.
Save gumeniukcom/1386401 to your computer and use it in GitHub Desktop.
mashinko
__author__ = '[email protected]'
# -*- coding: utf-8 -*-
class Car(object):
message = "Привет, я машинко"
def who(self):
print self.message
class DriftCar(Car):
def __init__(self):
self.message = "Я супер машинка"
class Buldozer(Car):
def __init__(self):
self.message = "А я бульдозер"
qwe = Car()
asd = DriftCar()
zxc = Buldozer()
qwe.who()
asd.who()
zxc.who()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment