Devin's Blog

Home

❯

Coding

❯

Valid Triangle Number

Valid Triangle Number

Mar 25, 20231 min read

  • idea

Note

Could be worth redoing 3Sum the good way, and also taking perhaps a look at 4sum

1st try: Valid Triangle Number 2023-03-25 15.28.28.excalidraw

  • Reached a O(N3) approach
    • Might be able to do DP to speed it up
  • It is either a sliding window or a 2 pointer problem.

References

https://leetcode.com/problems/valid-triangle-number/


Graph View

Created with Quartz v4.5.0 © 2026

  • GitHub
  • Discord Community