Question: 3-12. [5] Suppose you are given an input set S of n numbers, and a black box that if given any sequence of real numbers
![3-12. [5] Suppose you are given an input set S of](https://dsd5zvtm8ll6.cloudfront.net/si.experts.images/questions/2024/09/66f456713f472_94466f45670c3300.jpg)
3-12. [5] Suppose you are given an input set S of n numbers, and a black box that if given any sequence of real numbers and an integer k instantly and correctly answers whether there is a subset of input sequence whose sum is exactly k. Show how to use the black box O(n) times to find a subset of S that adds up to k
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
