Skip to content

Tag Archives: maths-log

Given an integer num, the task for every digit of the number is to find the highest power of 2 not exceeding that digit. Examples:… Read More
Given an array arr[] of size N, the task is to print the nearest power of 2 for each array element. Note: If there happens… Read More
Given two integers N and K, the task is to find the count of all possible N-digit numbers having sum of every K consecutive digits… Read More
Logarithm: is the inverse function of the exponentiation which means the logarithm value of a given number x is the exponent to another number. Below… Read More
Given two positive integers X and Y, the task is to find the MSB of X, in the given base Y. Examples: Input: X =… Read More
Given an integer N, the task is to find the highest power of 2 that is smaller than or equal to N. Examples: Input: N… Read More
Given two integers a and b, the task is to find the log of a to any base b, i.e. logb a. Examples: Input: a… Read More
Given a number N, the task is to find the log value of the factorial of N i.e. log(N!). Note: ln means log with base… Read More
Logarithmic function is the inverse to the exponential function. A logarithm to the base b is the power to which b must be raised to… Read More
Given two numbers , find which is greater . If , print a^b is greater If , print b^a is greater If , print Both… Read More
Given a positive integer N and K where  and  . The task is to check whether any permutation of digits of N equals any power… Read More
Given a number N. The task is to find the total Number of Digits in . Examples: Input: N = 3 Output: 3 If N=3,… Read More
You have given a number n. Check if a number can be represented in the form of pow(a, b) (a^b). Examples:  Input : 4 Output… Read More
Given an integer N. The task is to find the minimum number of log values needed to calculate all the log values from 1 to… Read More
Given an integer N, the task is to print all the substring of N without doing any conversion i.e converting it into a string or… Read More