Skip to content

Instantly share code, notes, and snippets.

@bchase
Created December 21, 2014 00:07
Show Gist options
  • Save bchase/9f8ee44f7bedaf4aca64 to your computer and use it in GitHub Desktop.
Save bchase/9f8ee44f7bedaf4aca64 to your computer and use it in GitHub Desktop.
(1..10).each do |num|
sleep 0.5
print "\r"
dashes, spaces = '-'*num, ' '*(10-num)
bar = "[#{dashes}#{spaces}]"
print bar
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment