## IntroSort or Introspective sort

Introsort(Introspective sort) is a comparison based sort that consists of three sorting phases. They are Quicksort, Heapsort, and Insertion sort. Basic concepts of Introsort and… Read More »

- Maximum element in a sorted and rotated array
- Count the triplets such that A[i] < B[j] < C[k]
- Complexity Analysis of Binary Search
- Interactive Problems in Competitive Programming
- Lazy Propagation in Segment Tree | Set 2
- Maximum Sum SubArray using Divide and Conquer | Set 2
- Find minimum steps required to reach the end of a matrix | Set - 1
- Sum of maximum of all subarrays | Divide and Conquer
- Kth smallest element in the array using constant space when array can't be modified
- Find minimum steps required to reach the end of a matrix | Set 2
- IntroSort or Introspective sort
- Cost Based Tower of Hanoi
- Cartesian tree from inorder traversal | Segment Tree
- Find the number of different numbers in the array after applying the given operation q times
- Modular Exponentiation of Complex Numbers
- Find an N x N grid whose xor of every row and column is equal

Introsort(Introspective sort) is a comparison based sort that consists of three sorting phases. They are Quicksort, Heapsort, and Insertion sort. Basic concepts of Introsort and… Read More »

Given an integer N. The following tasks are performed: The number is noted. The leading digit from N is subtracted from N and the resulting… Read More »

Given two integers A and B, the task is to calculate 22A % B. Examples: Input: A = 3, B = 5 Output: 1 223… Read More »

Given three integers X, N and M. The task is to find XXX…(N times) % M where X can be any digitfrom the range [1,… Read More »

Given a string str. You are allowed to delete only some contiguous characters if all the characters are same in a single operation. The task… Read More »

Given a range [L, R], the task is to find the sum i * countDigits(i)2 for all i ∈ [L, R] where countDigits(i) is the… Read More »

Given a spirally sorted matrix with N * N elements and an integer X, the task is to find the position of this given integer… Read More »

Given k sorted arrays of different length, merge them into a single array such that the merged array is also sorted. Examples: Input : {{3,… Read More »

Given a range [L, R] where L ≤ R, the task is to generate a random permutation of the sequence [L, L + 1, L… Read More »

Giving k sorted arrays, each of size N, the task is to merge them into a single sorted array. Examples: Input : arr[][] = {{5,… Read More »

Given N vertex where N is even. Initially there is no edge between any of the vertices. You are allowed to perform operation as illustrated… Read More »

Given a number X, the task is to find the minimum number N such that total set bits of all numbers from 1 to n… Read More »

Given a string S containing lowercase latin letters. A character c is called K-amazing if every substring of S with length atleast K contains this… Read More »

Given an array of N integers where array elements form a strictly decreasing and increasing sequence. The task is to find the smallest number in… Read More »

Given an array arr[] of N integers and number of queries Q. The task is to answer three types of queries. Update [l, r] –… Read More »