• lime!@feddit.nu
    link
    fedilink
    English
    arrow-up
    5
    ·
    edit-2
    10 days ago

    Note that only the highest exponent is relevant. With some work we could prove that for example O(n^3 + n^2 + n) is equivalent to O(n^3).

    just adding on for others that “some work” can be simply explained as figuring out the answer to “as n grows, which of n3, n2 or n affects the result the most?”

    • dfyx@lemmy.helios42.de
      link
      fedilink
      English
      arrow-up
      4
      ·
      10 days ago

      Yes, it’s pretty intuitive. A formal proof is still a bit more work than what I can fit in an ELI5 but at the same time simple enough that it can be given to a 2nd semester computer science student as an exercise.