Skip to content

Instantly share code, notes, and snippets.

@sirramongabriel
Last active December 22, 2015 02:58
Show Gist options
  • Save sirramongabriel/6406766 to your computer and use it in GitHub Desktop.
Save sirramongabriel/6406766 to your computer and use it in GitHub Desktop.
project_jukebox1 snippet
class Song
def initialize(self, artist, title, genre)
@song = Self.new
@artist = artist
@title = title
@genre = genre
end
end
class SongList
def initialize(song)
song_list = []
@song = song
end
end
class Communcate
def greeting
Puts Hello, type 'play' to hear a song, or 'add' to add a song to the list.
gets.chomp
if gets.chomp == 'play'
return song_list'
elsif gets.chomp == 'add'
return @song
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment