## Program to find last two digits of 2^n

Given a number n, we need to find the last two digits of 2n. Examples: Input : n = 7 Output : 28 Input :… Read More »

Given a number n, we need to find the last two digits of 2n. Examples: Input : n = 7 Output : 28 Input :… Read More »

Given two numbers N and D. The task is to find out the largest number smaller than or equal to N which contains the maximum… Read More »

You are given two planes P1: a1 * x + b1 * y + c1 * z + d1 = 0 and P2: a2 *… Read More »

We have a stick of length L where L is power of 2. The stick got broken at (n-1) randomly chosen points (lengths of parts… Read More »

Given value of N and K. The task is to find the sum of series till N-th term whose i-th term is given by Ti… Read More »

The Haversine formula calculates the shortest distance between two points on a sphere using their latitudes and longitudes measured along the surface. It is important… Read More »

Given three points (x1, y1, z1), (x2, y2, z2), (x3, y3, z3). The task is to find the equation of the plane passing through these… Read More »

Given a point (x1, y1) and a line (ax + by + c = 0). The task is to find the perpendicular distance between the… Read More »

Given the number of sides n of a regular polygon. The task is to find out the Interior angle and Exterior angle of the polygon.… Read More »

Given an infinite grid, initial cell position (x, y) and a sequence of other cell position which needs to be covered in the given order.… Read More »

Given the first two digits of a large number digit1 and digit2. Also given a number c and the length of the actual large number.… Read More »

Prerequisites: Generating Functions, Fibonacci Numbers, Methods to find Fibonacci numbers. The method of using Generating Functions to solve the famous and useful Fibonacci Numbers‘ recurrence… Read More »

Given a number N, place numbers from the range [1, N2] in an NxN matrix such that sum in every row is equal. Examples: Input:… Read More »

Prerequisites: Triangular numbers Tetrahedral numbers Given a value n, and the task is to print tetrahedral number series up to nth term. Examples: Input: 5… Read More »

Given the length, width, and height of a triangular prism, the task is to find the volume of the triangular prism. Examples: Input: l =… Read More »