DynamicProgramming

Question:

CanSum: Write a function canSum(targetSum, numbers) that takes in a targetSum and an array of numbers as arguments. The function should return a boolean indicating weather or not it is possible to generate the targetSum using numbers from the array. Note: all numbers in array are positive. You may use any number from the array as many times as you like.

HowSum: Write a function howSum(targetSum, numbers) that takes in a targetSum and an array of numbers as arguments. The function should return an array of numbers that sum up to targetSum. Note: all numbers in array are positive. You may use any number from the array as many times as you like.

BesttSum: Write a function bestSum(targetSum, numbers) that takes in a targetSum and an array of numbers as arguments. The function should return a shortest array of numbers that sum up to targetSum. Note: all numbers in array are positive. You may use any number from the array as many times as you like.