Last active
August 29, 2015 13:56
-
-
Save joseph-ravenwolfe/9318909 to your computer and use it in GitHub Desktop.
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
def performance | |
stores = {1 => 0, 2 => 0, 3 => 0, 4 => 0, 5 => 0} | |
stores.keys.each do |store_number| | |
print "Please enter the amount for store #{store_number}: " | |
stores[store_number] = (gets.chomp.to_i / 100).floor | |
end | |
puts "Sales Bar Chart" | |
stores.each do |store_number, amount| | |
puts "Store #{store_number}: #{'*' * amount}" | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment