clojure-hackos.apple-and-orange
Solution to the Apple and Orange challenge. See: https://www.hackerrank.com/challenges/apple-and-orange
count-apples-&-oranges
(count-apples-&-oranges s t a b apples oranges)
Returns the number of fallen apples and oranges that land within a given range, where:
s
is the start of the ranget
is the end of the rangea
denotes the location of the apple treeb
denotes the location of the orange treeapples
are the distances at which each apple falls from the treeoranges
are the distances at which each orange falls from the tree.