Understanding the Time Complexity of an Algorithm

Поделиться
HTML-код
  • Опубликовано: 27 ноя 2024

Комментарии • 30

  • @nesoacademy
    @nesoacademy  Месяц назад +2

    Algorithms Playlist: ruclips.net/p/PLBlnK6fEyqRhoF3cPp0mgOZPuXeu84nAd

  • @diwanshsawlani7028
    @diwanshsawlani7028 2 месяца назад +10

    00:08 Understanding priori vs posterior analysis of time and space complexity
    03:16 Understanding Priori Analysis for Algorithm Time Complexity
    06:26 Time complexity is the estimation of total CPU computations required to execute an algorithm.
    09:34 Analyzing the time complexity of a simple algorithm with frequency count method
    12:32 Understanding time complexity of algorithm instructions
    15:38 The frequency count of the instruction is n + 1.
    18:24 The time complexity of the algorithm depends on the number of times certain instructions are executed.
    21:10 Understanding time complexity of an algorithm
    23:47 Time complexity of algorithm is Big O

  • @TanvirAhmedOriginal
    @TanvirAhmedOriginal 3 месяца назад +9

    Thank you Neso Academy, for making our life easier.

  • @Dr_Larken
    @Dr_Larken 3 месяца назад +45

    The algorithm brought me here!

  • @subhamukherjee7442
    @subhamukherjee7442 27 дней назад +2

    Thanks you..this video has helped me...need more videos on DSA topic

  • @Think_First12
    @Think_First12 3 месяца назад +4

    Thank you for sharing in depth knowledge 🙏

  • @irappapatil8621
    @irappapatil8621 Месяц назад

    Clear pronunciation.Good video.

  • @eghanshith5346
    @eghanshith5346 2 месяца назад +2

    1.Priori vs. Posterior Analysis Recap:
    Priori analysis estimates time and memory space before executing an algorithm.
    Posterior analysis calculates them after execution.
    2.CPU Computations and Main Memory Space:
    CPU computations refer to tasks executed by the CPU (instructions).
    Main memory space stores data and instructions for quick access during execution.
    3.Time Complexity Estimation:
    Use the frequency count method.
    Calculate the sum of frequency counts for each instruction.
    Example: sum = 0 (1 unit), for (i = 1; i

  • @akashtiwari397
    @akashtiwari397 3 месяца назад +6

    Plz bring series of gate pyq year wise subject wise

  • @sujitsingh5862
    @sujitsingh5862 3 месяца назад +2

    better than previous

  • @yazidbessadet
    @yazidbessadet 3 месяца назад +2

    so much AURA i'm feeling right now cant lie LOL. NESO are the best

  • @Ehvan1729
    @Ehvan1729 2 месяца назад +2

    one thing i could say is just thanks
    i think that is very small one

  • @MuhammadAli-gh4do
    @MuhammadAli-gh4do 2 месяца назад

    very helpful

  • @salsalazar7646
    @salsalazar7646 2 месяца назад

    nice video well done amazing job

  • @AshvinParmar-ov2dv
    @AshvinParmar-ov2dv 2 месяца назад +1

    2 minute video took my 24 minutes

    • @AbdullahBRashid
      @AbdullahBRashid 2 месяца назад

      Fr. Dogshit video. Absolutely zero info on how to calculate more complex algorithms. Not worth 24 mins

  • @Gust52
    @Gust52 3 месяца назад +2

    Sir can you pls bring a course on networking? Like the many topics covered in ccna networking exam pls. It will add a depth of knowledge tobus and prepare us for that exam 🙏

  • @alfianabdulhalin1873
    @alfianabdulhalin1873 Месяц назад

    Although in the end, the main answer we're looking for is O(n)... just wondering about the sum = sum + a[i] part. Isn't it supposed to be 1? Because it's a one liner... I'm thinking in terms if we assign values to variables, say .... int a = 0, j = 9;

    • @subhamukherjee7442
      @subhamukherjee7442 27 дней назад

      NOt really because it involves two operations, addition(1 task) and assigning value(1 task)...this continues till n times

  • @u.aamir1
    @u.aamir1 18 дней назад

    any slides or notes available?

  • @mohamad.d1258
    @mohamad.d1258 3 месяца назад +2

    Well that's my problem.

  • @De1be1-00
    @De1be1-00 3 месяца назад +1

    For increment what I'd the time complexity

  • @TanvirAhmedOriginal
    @TanvirAhmedOriginal 3 месяца назад +2

    I don't understand why not O(4n+4)

    • @shahidiqbal512
      @shahidiqbal512 2 месяца назад

      I also asking same question.

    • @nicolasbarone2176
      @nicolasbarone2176 2 месяца назад +3

      Big O notation represents the sets of functions, which have to be above the original function, by a given constant c and a given value n0.
      In mathematical way: O(g(n)) = { f(n) | Exist two costant c > 0 and n0 > 0 : 0 = 4n + 1 by a given n0. For example if n0 = 20, the inequality will be: c * 20 >= 4 * 20 + 1; so, to make this inequality true, we can use c = 5. You can use any number that you want for the demonstration.
      If you were questioning if you could just write O(4n + 4) the answer is yes! But it's not as formal as writing O(n).
      I hope that is helpful :)

    • @TanvirAhmedOriginal
      @TanvirAhmedOriginal 2 месяца назад

      @@nicolasbarone2176 thanks

  • @footworld2335
    @footworld2335 3 месяца назад +1

    wow

  • @enough200
    @enough200 Месяц назад

    how 4n+4 became O(n)?

    • @muskanas78
      @muskanas78 Месяц назад

      constants are ignored