Last active
December 16, 2015 10:39
-
-
Save TXDynamics/5421452 to your computer and use it in GitHub Desktop.
Ruby Example pass parameter to helper
class
This file contains 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
#Displays the current date but repeat x times | |
def display_time(how_many_times) | |
p = how_many_times.to_i | |
return p.times {puts Time.now.strftime("%m/%d/%y")} | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I edited it to return the correct value