Given an array or a string, print all the permutations of it. A permutation of a string, is a rearrangement of the elements of the

# Tag: Arrays

## Spiral Order Traversal

You are given a N x N matrix, you need to perform a spiral order traversal and print the elements of the matrix in that

## Majority Element

Given an array, you need to find the majority element if it exists, else return “NO”. A majority element of an array of size N,

## Sort an array of 0’s, 1’s and 2’s

You are given an array whose elements are only 0’s, 1’s and 2’s. You need to sort the array in increasing order in linear time

## Minimum number of coins (DP-20)

You are given a value N and an infinite supply of some denomination of coins, you need to find out the minimum number of coins

## K – Palindromic String (DP-19)

You are given a string and a positive integer K. You need to determine if the string is K palindrome or not. A string is