Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/python
- class Tank:
- def __init__(self, tank_id, name, level):
- self.tank_id = tank_id
- self.name = name
- self.level = level
- def tank_info(self):
- print "Tank ID: {}, Tank Name: {}, Tank Level: {} ".format(self.tank_id, self.name, self.level)
- patton = Tank(2, 'patton', 3)
- patton.tank_info()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement