Created
February 5, 2010 14:31
-
-
Save lafeber/295827 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
class Integer | |
def to_leading_zero_string | |
(self < 10) ? "0#{self}" : self | |
end | |
end | |
#To get all episodes of kabouter Wesley, where 21 is the amount of episodes | |
21.times do |i| | |
system "wget http://kabouterwesley.pro-networks.nl/afleveringen/aflevering_#{(i+1).to_leading_zero_string}.mp4" | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment