Big O Notation Series (Coding): Merge Sort Made Easy

Поділитися
Вставка
  • Опубліковано 26 жов 2024

КОМЕНТАРІ • 13

  • @eleandro
    @eleandro 2 роки тому +1

    Just to let you know, I love the way you start your videos.

  • @fareed1983
    @fareed1983 2 роки тому

    Thanks for this series. Wishing you all the best for your career as a teacher where you can use the premium chalk creating the next generation of innovators.

  • @fcdarjan
    @fcdarjan 2 роки тому +1

    Man if we had you as our teacher at Rotterdam University, i would pay double for that.. damn man.

    • @kantancoding
      @kantancoding  2 роки тому

      Hope you did well on your exams! 🙂

  • @rohans4668
    @rohans4668 3 роки тому

    great way of explanation man...love it...keep it up

  • @LynnyrdRavage
    @LynnyrdRavage Рік тому

    I'm confused. At 5:04 you said that arr.length -1 would not include the last index in the array. So how come you typed "arr.slice(0, arr.length -1)" for the example? Thanks in advance.

    • @kantancoding
      @kantancoding  Рік тому

      I was talking about arr.slice(). arr.length - 1 is the last index of the array.

  • @9272fe
    @9272fe 2 роки тому +1

    what if n was devided by 3 instead of 2 would it still be O (log n) or would the base of log change to 3 ?

    • @kantancoding
      @kantancoding  2 роки тому +2

      Consider this: Log base 2 of 27 = log base 3 of 27 / log base 3 of 2 = C * log base 3 of 27 where C is a constant equal to 1 / log base 3 of 2. So because log base 2 of 27 and log base 3 of 27 only differ by the constant C, and because in Big O we ignore constants, they are both valid. So the base doesn’t matter but in my opinion, base 2 is more intuitive and more widely used in computer science

  • @b.mweinreb7991
    @b.mweinreb7991 Рік тому

    you are so creative man desreve a sub