Reversed thought: total no. of subsets - no. of subsets without arr[i] > k Solution 2: constructive solution: http://www.martinkysel.com/hackerrank-number-list-solution/