I\'m working through an interview question that goes like:
Given an array of integers and sum, check whether any combination adds up to the sum.>
If you have positive as well as negative integers, you are going to run into a combinatorial explosion, where whatever algorithm you choose will slow by a fixed percentage for every increase in length of your array. (If you only have positive integers, you can bound your search once the target sum is exceeded.)
A boundary question: are you allowed to reuse integers as well?
You should search for 'combinatorial algorithms'. Knuths' tome-in-progress could help you quite a lot if you want to dig deeper into the question.