Last active
December 18, 2015 07:32
-
-
Save jpotts18/19e030dafe397cef8802 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This gist is a continuation of a previous gist which defines the MorningAlgorithm class | |
# https://gist.github.com/jpotts18/1f4269c9e1f22c963a0d | |
class LateMorningAlgorith < MorningAlgorithm | |
def work_out | |
puts "Nope..." | |
end | |
def eat_breakfast | |
puts "Grab banana and go!" | |
end | |
end | |
late_morning = LateMorningAlgorithm.new | |
late_morning.execute | |
# The LateMorningAlgorithm.execute template method will call the following methods from the following classes | |
# wake_up - MorningAlgorithm | |
# work_out - LateMorningAlgorithm | |
# eat_breakfast - LateMorningAlgorithm | |
# drive_to_work - MorningAlgorithm |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment