Subarray Product Less Than K
Sliding Window
Problem
Your are given an array of positive integers nums
.
Count and print the number of (contiguous) subarrays where the product of all the elements in the subarray is less than k
.
For example:
Solution
Last updated
Was this helpful?