Back to course home
0% completed
Vote For New Content
There is a simple O(N) solution using sliding window.
Andrew McMillan
Dec 30, 2021
There is a simple O(N) solution using sliding window.
1
0
Comments
Comments
Design Gurus4 years ago
Can you share it? We are quite sure, it must be a different problem.
S
Syed Hassan4 years ago
there is'nt. good lucj
J
J 3 years ago
Andrew is likely talking about the closest LC equivalent problem https://leetcode.com/problems/subarray-product-less-than-k/ asks for the count of such subarrays instead.
Design Gurus3 years ago
Yes, finding the count can be done in O(n). Finding all the subarray will take O(n^2).
On this page