top of page

Divide and Conquer





Theory


It’s an approach for solving a problem where we first divide our problem into different then solve all of them separately by using a recursive approach and then combine all solved parts to have our final result.

Note: Recursion and Divide and Conquer both are different, in Recursion we don’t actually divide our problem we just call our method internally and solve it using the stack data structure. In Divide and Conquer approach we divide our problem into sub–problems and then combine them to have a complete solution to our problem.


Examples of Divide and Conquer are: Quick Sort, Merge Sort, etc.

Recent Posts

See All

What is GraphQL

GraphQL is more about get what you want. In a traditional REST APIs approach if we want to change the fields of response then we have...

Comments


bottom of page