Write a program to determine if a given number is a palindrome or not. A palindromic number is a number that remains the same when its digits are reversed.
Write a iterative C/C++ and java program to find factorial of a given positive number. The factorial of a non-negative integer n is the product of all positive integers less than or equal to n. It is denoted by n!. Factorial is mainly used to calculate number of ways in which n distinct objects …
Implement heap data structure.
In this article, we will introduce a very important data structure Priority Queues and discuss how we can implement them using (Binary) Heaps.
Find duplicate rows present in a given binary matrix by traversing the matrix only once.
In this post, we will see how to find maximum element from a List of Integers using Stream in Java 8.
Given a huge set of strings with duplicate strings present, find first k-maximum occurring words in it.
Given a huge set of strings with duplicate strings present, find the maximum occurring word in it. If two words have same count, return any one of them.
Lexicographic sorting: Given a set of strings, print them in Lexicographic order (dictionary/alphabetical order).
A stack is an linear data structure that serves as a collection of elements, with three main operations: push, pop and peek. We have discussed about these operations in previous post and covered array implementation of stack data structure. In this post, linked list implementation of stack is covered.
Find Longest Common Prefix (LCP) in given set of strings.
A stack is a linear data structure that serves as a collection of elements, with three main operations: