Divide and conquer
Divide and conquer
Introduction
Divide and conquer is an algorithmic technique in which a problem is solved using the “Divide, conquer, and combine” strategy.
A typical “Divide and conquer” algorithm solves a problem using the following three steps:
- Divide: splitting the problem into smaller subproblems.
- Conquer: solving the subproblems by recursive calls until they are solved.
- Combine: combining the subproblems to obtain the final solution to the original problem.
Application
Problem statement
Given an array of numbers. It is required to sort the array in using the “Divide and conquer” technique.