Skip to content

Instantly share code, notes, and snippets.

@akcrono
Created August 28, 2014 17:34
Show Gist options
  • Save akcrono/5f5fddffed4fbe1c8097 to your computer and use it in GitHub Desktop.
Save akcrono/5f5fddffed4fbe1c8097 to your computer and use it in GitHub Desktop.
class television
def initialize(make, model, type, channel = 3, volume = 5)
@make = make
@model = model
@type = type
@channel=channel
@volume=volume
end
def turn_on
end
def turn_off
end
def change_volume volume
@volume=volume
end
def change_channel channel
@channel=channel
end
end
class TV_Channel
def initialize (name, channel_number)
@name = name
@channel_number = channel_number
end
end
class TV_show
def initialize (name, channel_number, description)
@name = name
@channel_number = channel_number
@description = description
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment