Problems

Pick a problem and write your solution in the built-in editor. The judge runs it against real test cases while you watch, and the wider archive is open to read whenever you like.

Total results1,803 problems
TitleLevelTopicsSolvedTime limitMemory limitJudge
Make Rounddog HappyCount subarrays whose elements are all distinct and whose maximum minus length is at most k, for arrays up to 300,000 with values bounded by n.Hard9Divide and conquerTwo pointers+2No attempts yet2s512 MBJudgeable
OR and QueriesProcess range bitwise-OR updates on an array and count how many positions in a range currently equal a fixed K.Hard9Segment treeBit manipulation+2No attempts yet1.5s256 MBJudgeable
AtomsMaintain a sequence of charges under range add updates, and after restricting to a query segment, report the longest run of consecutive positions where each next charge exceeds the previous by exactly one.Hard9Segment treeDynamic programming+2No attempts yet2s512 MBJudgeable