Longest Alternating Subarray is a problem of finding a subarray with alternating positive and negative elements, and in which the subarray is as long as possible.
Write an efficient algorithm to reverse the specified portion of a given linked list.
Given an array of integers, find the length of longest subsequence formed by the consecutive integers. The subsequence should contain all distinct values and the character set should be consecutive, irrespective of its order.
Given an array and a positive number k, check whether the array contains any duplicate elements within range k. If k is more than size of the array, the solution should check for duplicates in the complete array.
Write an efficient algorithm to invert alternate levels of a perfect binary tree.
Write an efficient algorithm to construct a binary tree from given inorder and level-order sequence.
Given a string, find minimum number of deletions required to convert it into a palindrome.
Given three sorted arrays of variable length, efficiently compute the minimum range with at-least one element from each of the arrays.
Given a linked list with each node having an additional random pointer which points to any random node of the linked list or null, update the random pointer in each linked list node to point to node with maximum value to their right.
Given an unsorted array of integers, print all elements which are greater than all elements present to its right.