 In this learning activity, we'll learn what an algorithm is. Okay, I'm thinking of a number between one and a hundred. Guess what it is? Well, it could take you up to a hundred tries to guess correctly, right? If we were doing this face to face, would you just start at one and guess each number in a series? Would you shout out random numbers? If you did that, you'd have to keep track of the numbers you've already guessed. Is there a way to guess the number I'm thinking of that minimizes the number of guesses you'll need? These are great questions. The kind of questions computer programmers ask themselves every day. Turns out, there is a fast way to guess a number. Guess a number directly in the middle of the range of possible values, and I'll tell you if the number I'm thinking of is higher or lower. Let's say my number was sixteen. Your first guess will be in the middle of the range one to one hundred, or fifty. Sixteen is lower than fifty, so I say lower. You've just eliminated fifty one through one hundred. Let's do it again. Twenty-five? Lower. Twenty-five is in the middle of the range one to fifty. We've eliminated three-quarters of the numbers with just two guesses. Thirteen? Higher. Now the range is between fourteen and twenty-four. Nineteen? Lower. Now the range is between fourteen and eighteen. Sixteen? Correct! It only took you five guesses. This method I just showed you is an algorithm called the binary search. It is important that algorithms be as efficient as possible, so that a computer program implementing the algorithm will finish as quickly as possible. Have you ever alphabetized a list of names or other texts? I don't mean in a computer program, I'm talking about pen and paper. There's a method to that as well, one you probably learned in elementary or primary school. Do you remember how to alphabetize? Simply put, an algorithm is a method for doing something. A computer algorithm is a method for solving a problem or finding some answer. Algorithms aren't particular to any language. If you know the binary search algorithm, you can implement it in any computer programming language. Congratulations! You've just completed the what is an algorithm learning activity. In this learning activity we learned what an algorithm is.