What is an Algorithm?

Posted · Add Comment
What is an algorithm
Spread the love

An Algorithm Explained

An algorithm in principle is a series of step by step instructions in order to solve a problem or do something useful. They have an input which goes through a series of computations and finally produces an output.


An algorithm has a definite beginning and a definite end.




Algorithms are a formal way of describing very precisely how to carry out a certain task.


Simple Algorithms used in getting home from the airport:


  1. Go to the taxi stand.
  2. Get in a taxi.
  3. Give the driver my address.


  1. When your plane arrives, call my cell phone.
  2. Meet me outside baggage claim.


  1. Take the shuttle to the rental car place.
  2. Rent a car.
  3. Follow the directions to get to my house.


  1. Outside baggage claim, catch bus number 70.
  2. Transfer to bus 14 on Main Street.
  3. Get off on Elm street.
  4. Walk two blocks north to my house.

All four of these algorithms accomplish exactly the same goal, just in different ways with varying degrees of cost and time.

How can data be used to predict future events?

If you traveled weekly for work and had to utilize each one of these algorithms every time you returned home, we could use data from your previous trips to predict your transportation home on future trips.

For example, let’s say we had the data from your previous 100 trips. When examining the data closely, we observed some trends: most of the time when returning home before 5 pm, you usually took a bus to get home, after 5 pm, you typically called for a ride, and on rainy days, you typically took a cab home. We noticed that you rented a car once, but we dismissed that data as an outlier.

If you were returning home tomorrow at 3 pm and the weather was going to be nice, we could predict with a high level of certainty that you would be taking the bus home.

Here is an example of a woman who studied data trends from previous lotto winners to predict the winning numbers

  • Meet the “luckiest woman in the world”, she was “lucky” enough to win the lotto four times.
  • The odds of this have been calculated at one in eighteen septillion and luck like this could only occur once every quadrillion years.
  • First, she won $5.4 million, a decade later, she won $2 million, two years later $3 million, and in 2010, she hit a $10 million jackpot.
  • She happens to have a Ph.D. from Stanford with a specialization in statistics.
  • It’s believed Ms. Ginther figured out the algorithm.