subarray with given sum hackerrank