## Parentheses balancing Algorithm with recursion in Scala

If you are writing compilers for any language, it’s common practice to parse text and check for parsing errors. One

## Finding duplicates in an array using Hashtables -O(n)

We have seen the Brute force and sorted array solutions for the problem statement, Now to even minimize the time

## Finding duplicates in a sorted array – O(nlogn)

Duplicates in the array can be found by general Brute force solution in the O(n^2) time. Can there be any

## Finding Duplicates in an array -BruteForce [O(n^2)]

Finding duplicates in an array is a common interview question. The problem statement can be defined as follows. Given an

## Reversing an array using Recursion in Java

Reversing an array using Recursion is an example of Tail Recursion . We maintain two in-variants “i” and “j”. “i” holds

## Power of a given number using Recursion in Java

Power of a given number, x is a mathematical operation, written as  x^n. involving two numbers, the base x and the exponent  (or index or power)

## Factorial of a number using Recursion

Factorial of a number is defined as the product of natural numbers starting from 1 to the number that we

## Euclid’s Algorithm for finding GCD of two numbers

Finding Greatest Common Divisor (GCD of two numbers) is a simple mathematical problem, the algorithm (Euclid’s Algorithm) for which was