What is the difference between a computer program and an algorithm?

311 views

When I was growing up computer program was software. Now everyone talks about algorithm. What is the differance between the two?

In: 6

10 Answers

Anonymous 0 Comments

A computer program is a complete product that allow the user to accomplish some set of related tasks. A media player, a word processor, a game, etc. are all programs that have many related functions for some specific task or set of tasks.

An algorithm is a set of instructions and logic that accomplishes some goal. They can be very simple or very complex. They typically take some data, process it, and then return some result.

A simple algorithm might be one that takes a list of cities and tells you which two are the closest. It’s a simple calculation with a simple dataset.

A more complex algorithm might be one that takes a list of online shopping profiles, analyzes buying patterns, then recommends products to other shoppers with similar buying patterns.

A typical computer program is made of many algorithms that are each responsible for a different task within that program.

You are viewing 1 out of 10 answers, click here to view all answers.