title: Sub-array of integers with given sum, using recursion in C
body: <p>I have got a pretty hard task I find difficult to handle.</p>
  
  <p>I'm trying to write a recursive function (no loops at all) that, given an array and its length, will print a pair of sub arrays, each of which's sum will be half of the sum of the entire array. In other words, the array is to be divided into two groups of integers so that their sum is equal.</p>
  
  <p>For example, given the array {1,2,2,0,5}, the function should output {1,2,2} {0,5}</p>
  
  <p>I have to do it recursively, with a function that gets only the array itself and its size. I am also only allowed to use one more additional recursive function to solve the problem.</p>
  
  <p>Any thoughts or ideas will be most appreciated.</p>
  
  <p>Hello again! 
  we got a code in class that goes like this </p>
  
  <pre><code>int SubsetSum(int arr[], int idx, int n, int S) {
  if (S==0) return 1; //This is stopping condition #1.
  if (S&lt;0 || n==0) return 0; //This is stopping condition #2.
  ￼return SubsetSum(arr, idx+1, n-1, S-arr[idx]) || SubsetSum(arr, idx+1, n-1, S);
  }
  </code></pre>
  
  <p>what does the " || " operator means in terms of recursion? 
  thanks ppl! </p>