ScaleFree

DS & A (Problems, Algorithms and Programs)

| CHAPTER 2 |

As the header says this post is all about the terminologies: Problems, Algorithms, and Programs. I know many of you guys might think it's basic knowledge, but I still decided to dedicate a post to those terms because it is really important for someone learning Data Structures to know the precise meaning of those terms. So, Let's begin
What is a Problem?

A problem can be simply defined as a task to be performed.
  • Can be thought of a collection inputs and corresponding outputs.
  • A problem definition should include constraints on the resources that may be consumed by any acceptable solution.
What is an Algorithm?

An algorithm can be generally defined as a method to solve a problem.

Now, let's make the definition more specific. A more specific definition would be, algorithms are an unambiguous series of concrete steps to solve a class of problems.

Properties of an algorithm :
  • Should be correct
  • There should be no ambiguity
  • Series of Concrete steps
  • A finite number of steps / It should terminate
What is a program?

A program is an instance of an algorithm in some programming language.

( If you like the content here, follow TSP on social media to get notified on future updates)



Comments

Share on Social Media

Most Viewed Posts

DS & A (Lists - Array Based)

SPACE & DRAGONS

DATA STRUCTURES AND ALGORITHMS