loading...

re: Daily Coding Problem #1 VIEW POST

FULL DISCUSSION
 

arr, sum = [10, 15, 3, 7], 17
(arr.combination 2).any?{ |a| a[0] + a[1] == sum }

Code of Conduct Report abuse