« first day (2831 days earlier)      last day (1614 days later) » 

4:35 AM
-1
Q: Selecting elements from two array to get the target sum

KumarLet $A$ and $B$ are two arrays of size $n$ with positive integer values and let $k$ be any positive integer. Design an algorithm to solve the following problem. For each index $i$ ($1\leq i \leq n$) either select $A[i]$ or $B[i]$ but not both such that the sum of the elements picked from the a...

 

« first day (2831 days earlier)      last day (1614 days later) »