Algorithmic Strategies

Unit 4 > Computer Science > Class 12 > Samacheer Kalvi - English Medium

Objectives


• Know the basics and technical perspective of algorithms. • Understand the effi ciency, time and space complexity of an algorithm. • Develop and analyze algorithms for searching and sorting. • Learn about dynamic programming through algorithmic approach.

Summary


• An algorithm is a finite set of instructions to accomplish a particular task. • Algorithm consists of step-step-by instructions that are required to accomplish a task and helps the programmer to develop the program. • Program is an expression of algorithm in a programming language. • Algorithm analysis deals with the execution or running time of various operations involved. • Space complexity of an algorithm is the amount of memory required to run to its completion. • Big Oh is often used to describe the worst-case of an algorithm. • Big Omega is used to describe the lower bound which is best way to solve the space complexity. • The Time complexity of an algorithm is given by the number of steps taken by the algorithm to complete the process. • The efficiency of an algorithm is defined as the number of computational resources used by the algorithm. "• A way of designing algorithm is called algorithmic strategy. • A space-time or time-memory tradeoff is a way of solving a problem or calculation in less time by using more storage space. • Asymptotic Notations are languages that uses meaningful statements about time and space complexity. • Bubble sort is a simple sorting algorithm. It compares each pair of adjacent items and swaps them if they are in the unsorted order. • The selection sort improves on the bubble sort by making only one exchange for every pass through the list. • Insertion sort is a simple sorting algorithm that builds the final sorted array or list one item at a time. It always maintains a sorted sublist in the lower positions of the list. • Dynamic programming is used when the solutions to a problem can be viewed as the result of a sequence of decisions."