simp_pro's blog

By simp_pro, history, 2 years ago, In English

Problem link: https://leetcode.com/contest/weekly-contest-291/problems/k-divisible-elements-subarrays/

since n <= 200. O(n^3logn) solution should pass but it is giving TLE.

TLE submission link: https://leetcode.com/submissions/detail/751013225/

A few minutes ago, it had got accepted but its not getting accepted now.

AC submission link : https://leetcode.com/submissions/detail/751012624/

Can someone tell me why?

  • Vote: I like it
  • -1
  • Vote: I do not like it

| Write comment?
»
2 years ago, # |
  Vote: I like it +1 Vote: I do not like it

LC occasionally executes program with different runtime, with a slightly modified solution I got even 1500ms.