Search an Element in Sorted Rotated Array

In search in sorted rotated array problem we have given a sorted and rotated array and an element, check if the given element is present in the array or not. Examples Input nums[] = {2, 5, 6, 0, 0, 1, 2} target = 0 Output true Input nums[] = {2, …

Read more

Maximum Subarray

In the Maximum Subarray problem we have given an integer array nums, find the contiguous sub array which has the largest sum and print the maximum sum subarray value. Example Input nums[] = {-2, 1, -3, 4, -1, 2, 1, -5, 4} Output 6 Algorithm The goal is to find …

Read more

Merge Sort

What is merge sort? Merge Sort is a Recursive Procedure. It is also a divide and conquers algorithm. Now we need to know what divide and conquer algorithm is? It’s a type of procedure in which we divide the problem into subproblems and divide them until we find the shortest …

Read more

Infix to Postfix

What is an infix expression? Expression in the form of ‘operand’ ‘operator’ ‘operand’ is called infix expression. Example:  a+b What is postfix expression? Expression in the form of ‘operand’ ‘operand’ ‘operator’ is called postfix expression. Example:  ab+ What is the need of infix to postfix conversion? Infix expression is easy …

Read more

Translate »