blakeembrey/code-problems — pull request #120 by roitt (2014-09-22 21:59:35+00:00)
Title: Solutions considering duplicates in the array.

The existing solution was ignoring the duplicates in the array.
For example:
f(8, [3, 4, 5, 4, 4]) //Output: [ [3, 5], [4, 4]]

No changes have to made to the existing methods. But two new methods have been added which take duplicates into consideration.
For Example:
f(8, [3, 4, 5, 4, 4]) //Output: [ [3, 5], [4, 4], [4, 4], [4, 4]]