Number of subarray given a value less than k | Sololearn: Learn to code for FREE!

0

Number of subarray given a value less than k

Hi, I have a problem when elements in array are negative or zero. The output is not always correct. I find also another code on the internet that solves this problém differently, but it also always does not work. Please can someone help me. https://code.sololearn.com/c702gwDlOJmh/?ref=app My code looks almost like this. I cant insert my because I wrote it only on my PC. But I can copy it if it would be necessary.

11/22/2019 5:37:38 AM

patos

2 Answers

New Answer

+1

Can you elaborate more on this? I don't think I'm understanding what the code is trying to do. <lis> is a list, and it doesn't have any sub-list in it, so yeah, I'm lost.

+1

Can you explain what the problem is exactly? With no information about what the code is trying to achieve, or what the incorrect output is, it's really difficult to offer any sort of help.