Recap4:37 with Pasan Premaratne
Let's talk about the entire course!
We've arrived at what I think is a good spot to take a long break and 0:00 let all of these new concepts sink in. 0:03 But before you go off to the next course, 0:06 let's take a few minutes to recap everything we've learned so far. 0:08 While we did implement two algorithms in this course in actual code, much of 0:12 what we learned here was conceptual and will serve as building blocks for 0:16 everything we're going to learn in the future. 0:20 So let's list all of it out. 0:22 The first thing we learned about, and arguably the most important, 0:24 was algorithmic thinking. 0:28 Algorithmic thinking is an approach to problem solving that involves breaking 0:30 a problem down into a clearly defined input and output, along with a distinct 0:35 set of steps that solves the problem by going from input to output. 0:39 Algorithmic thinking is not something you develop overnight by taking one course. 0:44 So don't worry if you're thinking, well, 0:48 I still don't truly know how to apply what I learned here. 0:50 Algorithmic thinking sinks in after you go through several examples in 0:53 a similar fashion to what we did today. 0:57 It also helps to apply these concepts in the context of a real example, 0:59 which is another thing we will strive to do moving forward. 1:04 Regardless, it is important to keep in mind that the main goal here is not to 1:07 learn how to implement a specific data structure or 1:12 algorithm off the top of your head. 1:14 I'll be honest, I had to look up a couple of code snippets for 1:16 a few of the algorithms myself in writing this course. 1:19 But in going through this, you now know that binary search exists and 1:22 can it apply to a problem where you need a faster search algorithm. 1:27 Unlike most courses where you can immediately apply what you have learned to 1:31 build something cool, learning about algorithms and 1:35 data structures will pay off more in the long run. 1:38 The second thing we learned about is how to define and implement algorithms. 1:41 We've gone over these guidelines several times, so 1:46 I won't bore you here again at the end. 1:49 But I will remind you that if you're often confused about how to effectively break 1:51 down a problem in code to something more manageable, 1:55 following those algorithm guidelines is a good place to start. 1:58 Next, we learned about big O and measuring the time complexity of algorithms. 2:02 This a mildly complicated topic, but once you've abstracted the math away, 2:07 it isn’t as hazy a topic as it seems. 2:12 Now don't get me wrong, the math is pretty important, but only for 2:14 those designing and analyzing algorithms. 2:18 Our goal is more about how to understand and evaluate algorithms. 2:20 We learned about common runtimes like constant, 2:25 linear, logarithmic and quadratic runtimes. 2:28 These are all fairly new concepts. 2:31 But in time, you will immediately be able to distinguish 2:34 the runtime of an algorithm based on the code you write and 2:37 have an understanding of where it sits on an efficiency scale. 2:40 You will also, in due time, internalize runtimes of popular algorithms, 2:43 like the fact that binary search runs in logarithmic time and constant space. 2:48 And be able to recommend alternative algorithms for a given problem. 2:53 All in all, over time, the number of tools in your tool belt will increase. 2:57 Now next, we learned about two important search algorithms and 3:02 the situations in which we select one over the other. 3:06 We also implemented these algorithms in code so 3:09 that you got a chance to see them work. 3:12 We did this in python, but if you are more familiar with a different language and 3:14 haven't gotten the chance to check out the code snippets we've provided, 3:18 you should try your hand at implementing it yourself. 3:22 It's a really good exercise to go through. 3:25 Finally, we learned about an important concept and 3:27 a way of writing algorithmic code through recursion. 3:31 Recursion is a tricky thing, and depending on the language you write code with, 3:34 you may run into it more than others. 3:39 It is also good to be aware of, because as we saw in our implementation of binary 3:41 search, whether recursion was used or not affected the amount of space we used. 3:46 Don't worry if you don't fully understand how to write recursive functions. 3:51 I don't truly know either. 3:55 The good part is you can always look these things up and 3:57 understand how other people do it. 4:00 Any time you encounter recursion in our courses moving forward, 4:02 you'll get a full explanation of how and why the function is doing what it's doing. 4:06 And that brings us to the end of this course. 4:11 I'll stress again that the goal of this course was to get you prepared for 4:14 learning about more specific algorithms by introducing you to some of the tools and 4:18 concepts you will need moving forward. 4:22 So if you're sitting there thinking, I still don't 4:25 know how to write many algorithms or how to use algorithmic thinking, that's okay. 4:27 We'll get there. 4:31 Just stick with it. 4:32 As always, have fun and happy coding. 4:34
You need to sign up for Treehouse in order to download course files.Sign up