Function to return the number of total possible combinations of 0 and 1 to form an array of size N having sum of product of consecutive elements K
int combinationsPossible ( int N , int idx , int prev , int val , int K , vector < vector < vector < int > > > & dp ) {