Advertisement
Guest User

Untitled

a guest
Jul 30th, 2014
211
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.61 KB | None | 0 0
  1. class Song():
  2.  
  3.     def __init__(self, lyrics):
  4.         self.lyrics = lyrics
  5.  
  6.     def sing_me_a_song(self):
  7.         for line in self.lyrics:
  8.             print (line)
  9.     def split_that_shit(self):
  10.             new_text = self.lyrics
  11.             new_text = new_text.split()
  12.             print (new_text)
  13. happy_bday = Song(["Happy birthday to you",
  14.                    "I don't want to get sued",
  15.                    "So I'll stop right there"])
  16.  
  17. bulls_on_parade = Song("They rally around tha family" +
  18.                         "With pockets full of shells")
  19.  
  20. a = Song
  21. a.split_that_shit(bulls_on_parade)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement