JavaScript Algorithms Crash Course - Learn Algorithms & "Big O" from the Ground Up!

แชร์
ฝัง
  • เผยแพร่เมื่อ 19 พ.ค. 2020
  • If you want to get a job as a developer or if you simply want to grow and become better, you need to be able to solve problems. You need to be able to come with so-called "algorithms" - solutions that solve problems in code. This tutorial teaches you all about JavaScript algorithms from the ground up, step-by-step. We'll dive into the basics, time complexity and the "Big O" notation and explore how we can derive and compare algorithms.
    Join the full "JavaScript Algorithms - The Fundamentals" course: acad.link/js-algorithm-fundam...
    Check out all our other courses: academind.com/learn/our-courses
    ----------
    • Go to www.academind.com and subscribe to our newsletter to stay updated and to get exclusive content & discounts
    • Follow @maxedapps and @academind_real on Twitter
    • Follow @academind_real on Instagram: / academind_real
    • Join our Facebook community on / academindchannel
    See you in the videos!
    ----------
    Academind is your source for online education in the areas of web development, frontend web development, backend web development, programming, coding and data science! No matter if you are looking for a tutorial, a course, a crash course, an introduction, an online tutorial or any related video, we try our best to offer you the content you are looking for. Our topics include Angular, React, Vue, Html, CSS, JavaScript, TypeScript, Redux, Nuxt.js, RxJs, Bootstrap, Laravel, Node.js, Progressive Web Apps (PWA), Ionic, React Native, Regular Expressions (RegEx), Stencil, Power BI, Amazon Web Services (AWS), Firebase or other topics, make sure to have a look at this channel or at academind.com to find the learning resource of your choice!

ความคิดเห็น • 268

  • @moussaibrahem9
    @moussaibrahem9 3 ปีที่แล้ว +64

    3:40 Algorithms:What and Why?
    5:32 What is the "Best Possible Solution"?
    6:43 Measuring Performance (Time Complexity Big O)
    23:12 Deriving Big O (Asymptotic Analysis)
    25:20 Measuring Performance (Time Complexity - Big O)
    25:50 Deriving the Time Complexity Function
    34:36 Deriving Constant Time Complexity
    39:26 Using Big O to Compare Algorithms
    43:08 Practice Time!

  • @SiddharthRay1
    @SiddharthRay1 4 ปีที่แล้ว +176

    I think this is one of the course everyone was waiting for , for a lot time from max ❤

    • @academind
      @academind  4 ปีที่แล้ว +20

      I hope that you will like it :)

    • @SiddharthRay1
      @SiddharthRay1 4 ปีที่แล้ว +6

      @@academind for sure 🥰

    • @learnprogrammingwithproject
      @learnprogrammingwithproject 4 ปีที่แล้ว +1

      Truly, I'm eagerly waiting for this series.
      Thank you so much

    • @rifatspk
      @rifatspk 4 ปีที่แล้ว

      Exactly! I was waiting for a course like this. ❤❤❤❤

    • @TannerGrantDesign
      @TannerGrantDesign 3 ปีที่แล้ว

      I am so thankful for such a wonderful teacher. Just the content I am needing at just the right time!

  • @thedev966
    @thedev966 3 ปีที่แล้ว

    This is literally the best video I could find about Big O notation on youtube. This video not only covers a theoretical aspect but practical examples as well. Thank you!

  • @uhN0id
    @uhN0id 3 ปีที่แล้ว +8

    You are absolutely the best programming teacher on YT. Props to everyone who makes this content but yours is above and beyond. Always.

  • @vennelakantihemanth8719
    @vennelakantihemanth8719 4 ปีที่แล้ว +5

    Ahh Max ! Few days back I thought about this course & Here you are. I really love all of your courses because you are the best. Very detailed explanation of each and every concept. Please continue on Data Structures & Algorithms in JavaScript as well.

  • @siddhantjain2402
    @siddhantjain2402 4 ปีที่แล้ว +66

    This my 2 years of B.Tech in 1 hour. The rest of the course will cover the next 2 years. Why am I paying my college again?
    Edit: The course is excellent Max! Thanks!

    • @thinkingaloud7925
      @thinkingaloud7925 3 ปีที่แล้ว

      I completed ECE course in Btech and learnt this in 1 hour for free

    • @sethurk
      @sethurk 3 ปีที่แล้ว

      lol! And its free...

    • @mriduldey3305
      @mriduldey3305 3 ปีที่แล้ว +1

      It seems you guys need to study harder, this the basic part of first chapter of your algorithm book

    • @saurabhjainwal4604
      @saurabhjainwal4604 3 ปีที่แล้ว +1

      @@mriduldey3305 damn right they need to do that right away, learning from TH-cam is great, but it's nothing compared to the teaching of a prof.

    • @nishantkumar6960
      @nishantkumar6960 2 ปีที่แล้ว +1

      @@mriduldey3305 Nooooo. No one needs to study harder. We need to study in the right way and he did perfectly fine. He chose a source he feels comfortable with. Please don't impose your way of doing things on others.

  • @samiaghezal
    @samiaghezal 3 ปีที่แล้ว +17

    Thank you. Comprehensive, deep yet simple and aims to pass the fundamentals of real skills not just information. Well designed and prepared lecture. Your content, sir, is literally one of the best quality for web dev online that I came across.

  • @snimerjotsingh5561
    @snimerjotsingh5561 4 ปีที่แล้ว +2

    There are so many ads.
    But, I was struggling to learn BIG O. Know I understand, Thank you for making this video. KEEP MAKING THESE TYPES OF VIDEOS

  • @TheKenp25
    @TheKenp25 3 ปีที่แล้ว +1

    This is the best explanation of big O notation I have had, before even completing the tut

  • @ImamTaufikFirdaus
    @ImamTaufikFirdaus 4 ปีที่แล้ว +1

    Just want to say thanks.. i subscribed to academind pro and get a lots of things that i have missed before.. you help me out to understand more in JavaScript.. and your new video just awesome..

  • @asmereg
    @asmereg 3 ปีที่แล้ว +1

    You speak my mind. Teaches exactly what I'm confused about. Thanks

  • @juanrivas3941
    @juanrivas3941 3 ปีที่แล้ว +3

    This video is great, I’ve spent a few hours reading about Big O notation in articles and a couple of book and couldn’t quite understand until I watched this video because is so much better explain and more clear. Thanks for this great intro to algorithms!

    • @taiwomercy4915
      @taiwomercy4915 ปีที่แล้ว

      Same here!
      I have spent hours reading about Big O, and still didn't get it. Until today when I came across this video

  • @milemijatovic3403
    @milemijatovic3403 4 ปีที่แล้ว +1

    Thank you Max for this Algorithms Course :) I asked you about this topic when you was live on TH-cam few days ago :) This is what i have been waiting for a long time

  • @mbalekagheni4450
    @mbalekagheni4450 ปีที่แล้ว +1

    This was really a result of many hours of research, thanks for the clear explanation👏

  • @Rafael987_00
    @Rafael987_00 3 ปีที่แล้ว +4

    Great video and introduction!
    A tip: using Chrome tools (or new Edge, based on Chromium), if you are writing a function and open a bracket (without closing) you can press Enter. It won't submit until you type the closing bracket and press Enter.

  • @klutzy_
    @klutzy_ 3 ปีที่แล้ว

    Best algorithm course on TH-cam. Thanks for the video.

  • @orassayag
    @orassayag 4 ปีที่แล้ว +1

    Hi Max, great course! can't wait to see more. One thing to note, you need to edit this video, there is a large amount of cut sentences you say, and a black screen for a long time in the middle of this video.

  • @bmejia220
    @bmejia220 2 ปีที่แล้ว

    Yeah Max definitely getting your course man. I love this video. I'll be getting your course as soon as I solve the knapsack problem 😁

  • @anand_dudi
    @anand_dudi ปีที่แล้ว

    I must say you are one of the most well tutore on youtube as far as i know.
    Einstein said if you can explain it simply ,you understood that.
    This apply to you very well
    you are Great!

  • @dawid_dahl
    @dawid_dahl 4 ปีที่แล้ว +4

    Will definitely buy this course, thank you!

  • @nextrie
    @nextrie 4 ปีที่แล้ว +1

    Yay, that's my type of content right there! Thanks Max!

  • @brunoramiresferreira4011
    @brunoramiresferreira4011 4 ปีที่แล้ว

    You are sinister. You taught me a lot of things. Thanks Academind for all.

  • @anujupadhyay10
    @anujupadhyay10 4 ปีที่แล้ว

    Thanks man,,, I was definitely waiting for this one...!!

  • @willowsongbird
    @willowsongbird 3 ปีที่แล้ว

    This video was amazing! It was very easy to follow through the explanation

  • @FangerZero
    @FangerZero 2 ปีที่แล้ว

    Thank you very much for this, for the first time in my life I realize I've been doing algorithms my entire career, and now understand the importance of Big O in the first 2 minutes. I kind of feel dumb too for not realizing it lol

  • @harikotha7
    @harikotha7 4 ปีที่แล้ว +1

    Thanks Max,
    Been searching for this kind of video for a while! You read my mind ❤️
    Stay Safe 😊

  • @prakad97
    @prakad97 4 ปีที่แล้ว

    You are the man, there are no courses that explain algorithms and datastructures in javascript..waiting for the upcoming videos..appreciate the effort man..!!

    • @academind
      @academind  4 ปีที่แล้ว +1

      Thanks a lot!

  • @0xcadabra
    @0xcadabra 2 ปีที่แล้ว

    Great explanation Max! You're always the best teacher!

  • @kirant9339
    @kirant9339 4 ปีที่แล้ว

    Thanks Max for giving this course. As usual your video are awesome Thank you.

  • @deansolistino
    @deansolistino 3 ปีที่แล้ว

    This is the---most-clear explanation of BIG O

  • @adrienconversanodbl_g5119
    @adrienconversanodbl_g5119 2 ปีที่แล้ว

    In the 25 first minutes I understood what no one else in TH-cam is capable of explaining despite trying so hard in long and failed so called algorithm tutorials

  • @philly_zzz6147
    @philly_zzz6147 ปีที่แล้ว

    Max, you are the man for making this stuff understandable. I finally am able to grasp the nitty gritty and I thank you so much for that

    • @academind
      @academind  ปีที่แล้ว

      So happy to hear that! Thank you so much!

  • @Rafaelprog
    @Rafaelprog 3 ปีที่แล้ว

    perfect explanation .... after having seen many videos this is the best

  • @nChauhan91
    @nChauhan91 4 ปีที่แล้ว +2

    Thanks for this, needed it.

  • @britneyh8679
    @britneyh8679 2 ปีที่แล้ว

    Perfectly clear explanation 😭 thank you

  • @swastikrocker123
    @swastikrocker123 3 ปีที่แล้ว +1

    I was asked this question today in my interview for software engineer.

  • @parrotlover9035
    @parrotlover9035 ปีที่แล้ว

    Great stuff, thank you!! Just for fun, I used the performance.now() method to compare the time performance of your last two examples using for/of and .reduce. After repeating the test 30+ times, it turns out that the last example using .reduce seems to be faster about 90% of the time.

  • @ricardodutraalvarez9590
    @ricardodutraalvarez9590 3 ปีที่แล้ว

    Very good and detailed explanation, well planned class. Thanks for the video!

  • @ayushsingh3967
    @ayushsingh3967 3 ปีที่แล้ว

    Basics of time complexity very well explained!!👌

  • @elliotanderson2544
    @elliotanderson2544 ปีที่แล้ว

    Thanks, this Video will be helpful for beginner's.

  • @ankesh251
    @ankesh251 3 ปีที่แล้ว

    Great explanation, haven't understood this before this video

  • @hariharan7257
    @hariharan7257 4 ปีที่แล้ว

    Thanks max waiting for this course for a long time. When will be full version coming up ?

  • @mattoattacko
    @mattoattacko 3 ปีที่แล้ว

    This is excellent! Great work.

  • @sahidulislamjony5769
    @sahidulislamjony5769 2 ปีที่แล้ว

    It is one of the best videos of you. Thank you

  • @swoorp
    @swoorp 3 ปีที่แล้ว

    You explain very well Sir Max!

  • @ikechukwu1peter
    @ikechukwu1peter 2 ปีที่แล้ว

    Thank you so much for this course.

  • @richardstudent4139
    @richardstudent4139 3 ปีที่แล้ว

    Wonderful overview... Thank you very much!!!!

  • @spaceenthusiast5696
    @spaceenthusiast5696 3 ปีที่แล้ว

    Great work Max,thanks !

  • @karlhotz2605
    @karlhotz2605 2 ปีที่แล้ว

    This video was really easy to understand ! thanks

  • @bvsanchez6161
    @bvsanchez6161 2 ปีที่แล้ว

    I have about a month studying javascript and word problems and honestly right off the bat the first word problem killed me. At least I know what I need to work on

  • @chrys003
    @chrys003 4 ปีที่แล้ว

    Thanks so much for this course.

  • @gvinianidzegivi
    @gvinianidzegivi 3 ปีที่แล้ว

    More videos like this, thanks to Academind/Max!

  • @chinosts
    @chinosts 4 ปีที่แล้ว +1

    Great video! Thanks for going to the trouble of explaining this in such a succinct and clear way.

  • @eumm11
    @eumm11 3 ปีที่แล้ว

    amazing lesson, thank you!

  • @the7odmelmoney
    @the7odmelmoney 4 ปีที่แล้ว

    This video is very helpful. Thank you.

  • @elenemetreveli1523
    @elenemetreveli1523 ปีที่แล้ว

    Hey, great explanation! Is there a part 2 of this tutorial that I could watch?

  • @martinclason2432
    @martinclason2432 2 ปีที่แล้ว

    I'm not typically one to gush in TH-cam comments, but you rock Max

  • @VenkateshMogili
    @VenkateshMogili 4 ปีที่แล้ว +2

    Great video on Algorithms. Simple and Great teaching, I might have u as my Algorithms mentor when I was in college☺☺☺

  • @mortkebab2849
    @mortkebab2849 4 ปีที่แล้ว

    Does the course have exercises for each section with some way of getting help if you get stuck?

  • @thatWebGuySolutions
    @thatWebGuySolutions 11 หลายเดือนก่อน

    As always good stuff!

  • @dezinrtom7783
    @dezinrtom7783 2 ปีที่แล้ว

    Great content and straight to core. 🧡

  • @ashatron656
    @ashatron656 2 ปีที่แล้ว

    16:12 is best bit. Schwarzmüller Easter Egg, like fight club! 😂

  • @donxnik
    @donxnik 4 ปีที่แล้ว +15

    Max I have a hearing problem could you please turn on Captions?

  • @hodasalah1663
    @hodasalah1663 ปีที่แล้ว

    thanks thanks for this awesome course

  • @varunsukheja949
    @varunsukheja949 4 ปีที่แล้ว

    Hi, can you please tell the best source to read advanced JS concepts like this, bind, call, apply, scopes, prototypes, etc. in-depth?

  • @shutterradio
    @shutterradio 4 ปีที่แล้ว

    Wow. It wasn't that scary after all. Thanx you Max!

  • @TomSkinner
    @TomSkinner 2 ปีที่แล้ว

    Interesting point about the .reduce function having its own complexity. This makes it difficult to estimate time complexity. For instance, you assumed that (n)(n+1)\2 is O(1), but as far as I know the algorithm that is implemented at the machine level to evaluate divisions and multiplications may actually be a higher complexity. Maybe not, but it takes more knowledge than simply looking at the code. On the other hand I may be wrong 😄

  • @princeonukwili996
    @princeonukwili996 ปีที่แล้ว

    Thank you Max, you don't know how much you just helped me understand this😭...I was introduced to Data structures and algorithms by a friend and went ahead to research further, but until now no course i found on TH-cam was clear enough😭😭. Thanks so much and I'll be sure to get the full course on Udemy right after i finish your react js and Mern stack course on Udemy😂😅

  • @abulle5609
    @abulle5609 3 ปีที่แล้ว

    awesome lecture. thanks.

  • @CptBongue
    @CptBongue 3 ปีที่แล้ว

    I thought of doing an eval on joining the array with "+" as a join. Probably would have performed better on longer arrays

  • @mohdnawazishalam3255
    @mohdnawazishalam3255 4 ปีที่แล้ว

    This is the most awaiting course...love from india

  • @SandeepKumar-cx7cz
    @SandeepKumar-cx7cz 3 ปีที่แล้ว

    22:00
    big O, is a symbols that represents 'time complexity'.

  • @JordonDev
    @JordonDev 2 ปีที่แล้ว

    Shift + Enter one of the most important things in this video!

  • @imback6343
    @imback6343 3 ปีที่แล้ว

    superrbb way and easy to understand .. 😍😍

  • @petr8375
    @petr8375 4 ปีที่แล้ว

    Great, thank you for your work

  • @daudiabedi5614
    @daudiabedi5614 2 ปีที่แล้ว

    Best Tutor on the planet 🤛

  • @rajbannasa7662
    @rajbannasa7662 2 ปีที่แล้ว

    Thank you so much sir ❤️

  • @DonYurik
    @DonYurik 3 ปีที่แล้ว

    Great video!! What i was wondering with the functions subNumbers is if it is possible to reduce the functions complexity to lineal by using recursion, but i suspect it is the case of a loop "disguised" as a one line statement. I coded and tried an example, but when I try it in my browser it throws very different numbers even when I execute the same example.
    let exampleArrayOne=[1,3,10];
    let exampleArrayTwo=[1,3,10,50];
    let exampleArrayThree=[1,3,10,50,1,3,10,50,1,3,10,50,1,3,10,50]
    let exampleArrayFour=[1,3,10,50,1,3,10,50,1,3,10,50,1,3,10,50,1,3,10,50,1,3,10,50,1,3,10,50,1,3,10,50]
    function sumNums(array, pos){
    if(pos=array.length){
    pos=array.lengh-1;
    }
    else return array[pos]+sumNums(array,pos-1);
    }
    let start = 0;
    let end = 0;
    start=performance.now();
    sumNums(exampleArrayThree,exampleArrayThree.length-1);
    end=performance.now();
    end-start;

  • @yogidad
    @yogidad 4 ปีที่แล้ว

    Most awaited course

  • @PauloSantos-yu1tn
    @PauloSantos-yu1tn 4 ปีที่แล้ว

    Very good stuff. Thanks

  • @lasindunuwanga5292
    @lasindunuwanga5292 2 ปีที่แล้ว

    Wow you explain really good ❤️

  • @maiaklimenko6614
    @maiaklimenko6614 3 ปีที่แล้ว

    Why is for-loop better than reduce, if it is pretty much the same thing? Does it consume more time due to being called from outside the current js document?

  • @arnab1prince
    @arnab1prince 4 ปีที่แล้ว

    Please bring a course of competitive programming using javascript

  • @kevin_neugebauer
    @kevin_neugebauer 2 ปีที่แล้ว

    great tutorial!

  • @b.naveenkumar7662
    @b.naveenkumar7662 3 ปีที่แล้ว

    sir, you are relay amazing wonderful explanation

  • @sidforreal
    @sidforreal 4 ปีที่แล้ว

    Does this course cover data structures like graphs and trees?

  • @sivar8571
    @sivar8571 4 ปีที่แล้ว

    Max the whole video is blurry. Can you fix it out? Thanks in advance for this type of video. This video will help me a lot.

  • @dgloria
    @dgloria 4 ปีที่แล้ว +2

    great vid, but you didnt finish editing it. see 37 min. Thanks, I've been looking into this hundred times, couldn't understand it, now I do.

  • @nini-ic7is
    @nini-ic7is 2 ปีที่แล้ว

    amazing course

  • @alhaquekhan938
    @alhaquekhan938 2 ปีที่แล้ว

    In last problem if we spread an array then add it by our mathematical formula then may be we get a constant time complexity .
    Correct me If I'm wrong .

  • @seanmee8639
    @seanmee8639 2 ปีที่แล้ว

    For the sumOfArray problem, if security is not a factor (which it really always should be), you could make it a one liner by using eval.
    `return eval(array.join("+"))`
    not recommended though :D

  • @ProgramWithBalaji
    @ProgramWithBalaji 4 ปีที่แล้ว

    Most awaited course. Thanks for this course.

  • @Anuj_Kumar_1
    @Anuj_Kumar_1 4 ปีที่แล้ว

    Thanks i'm looking for data structure using JS... ☺

  • @duresameen4964
    @duresameen4964 4 ปีที่แล้ว

    Hi I like it,, will see the video and review again

  • @semyonshcherbinin3689
    @semyonshcherbinin3689 4 ปีที่แล้ว

    Thank you!

  • @yinkadhade363
    @yinkadhade363 ปีที่แล้ว

    Great course

  • @bobby8630
    @bobby8630 2 ปีที่แล้ว

    Hi guys, is the mathematical formulas CS/Math students know already? I solved the algorithm using the for loop and was wondering how people know these math formuluas, maybe I need to go through some math foundation concepts...

  • @ShahabAffan
    @ShahabAffan 2 ปีที่แล้ว

    Hey, great tutorial, loved it. thank you for the wonderful explaination.. I was just trying it and came up with this, is it something O(log n) for this problem in the end of summing elements of the array ?? It does reduce the number of executions.
    const sumUp = (n) => {
    let sum = 0
    for (let i = 0; i < n.length; i += 2) {
    if (i + 1 < n.length)
    sum += n[i] + n[i + 1]
    else
    sum += n[i]
    }
    return sum
    }

  • @ganeshkhirwadkar4127
    @ganeshkhirwadkar4127 2 ปีที่แล้ว

    @Academind - Do we have same course available on udemy ?

  • @Alex-bc3xe
    @Alex-bc3xe 3 ปีที่แล้ว

    very good stuff.