# Tagged: MISC

## Find numbers which are palindrome in both their decimal and octal Representations

Objective: Given a range of integers, find all the numbers which are palindrome when they are represented in Decimal Value( base 10) and in Octal value(base 8). Example : Number : 373 (Decimal) and...

## Colorful Numbers

Objective: Given a number, find out whether its colorful or not. Colorful Number: When in a given number, product of every digit of a sub-sequence are different. That number is called Colorful Number. See...

## Goldbach’s Conjecture

Goldbach’s conjecture – Every even integer greater than 2 can be represented as the sum of two primes numbers. Example: Given Number : 200 Prime Numbers are 3 197 Prime Numbers are 7 193...

## Convert Decimal into Irreducible Fraction

Objective: Given a decimal number, convert it into irreducible fraction. Irreducible Fraction : An irreducible fraction is a fraction in which the numerator and denominator are integers that have no other common divisors than...

## Clock Angle Problem

Objective: Find the Angle between hour hand and minute hand at the given time. Example: Time : 12:45 Input : hour = 12, Minute = 45 Output : 112.5 Time : 3:30 Input :...

## Sort 3 Integers without using if condition OR use only Max() function.

Objec­tive: – Given three integers, sort them without using if condition. Appraoch: Say 3 integers are, a, b, c. Find the maximum of a, b, c using Max() function. multiply all integers by -1....

## Euclidean algorithm – Greatest Common Divisor(GCD)

The greatest common divisor (GCD) of two or more integers, when at least one of them is not zero, is the largest positive integer that divides the numbers without a remainder. For example, the...