Last active
August 29, 2015 14:27
-
-
Save banta/283ec53ec1cacbb7d26f to your computer and use it in GitHub Desktop.
Code challenge 002
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
price_ranges = [{c_name: "Company A", range: [1000, 3000]}, {c_name: "Company B", range: [6000, 10000]}, {c_name: "Company C", range: [500, 2500]}] | |
# Given such a list and the disered price range a shopper wishes to pay, return the companies the shopper should examine. | |
# @param [Interger, Interger] | |
# | |
# @return [Array] | |
# | |
# @example | |
# examine_companies(2500, 5000) | |
# #=> [{c_name: "Company A", range: [1000, 3000]} {c_name: "Company C", range: [500, 2500]} | |
# | |
def examine_companies(low, high) | |
#TODO Implement the method | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@banta, price_ranges array does not have a closing square bracket(])