Tech
Forums
Jobs
Books
Events
Videos
Live
More
Interviews
Certification
Training
Career
Members
News
Blogs
Contribute
An Article
A Blog
A Video
An Ebook
An Interview Question
Register
Login
1
Answer
Add possible combinations of r elements in a given array
Ashish Sahu
9y
429
1
Reply
Hi Experts,
Add all possible combinations of r elements in a given array of size n
Example: is input array
int[] arr = new int[] { 1, 2, 3, 4, 5,6 };
output: possible combination of arrary below:
1+4+5=10
2+3+5 =10
1+2+3+4=10
6+4=10
6+1+3=10
please help me
Thanks & Regards
Ashish Kumar Sahu
Post
Reset
Cancel
Answers (
1
)
Next Recommended Forum
count fibonacci numbers as number of string over alphabet
error