# Tag Archives: number-digits

## Convert to number with digits as 3 and 8 onlyNovember 20, 2017

A charming number is a number which only consist 3 and 8 as its digits. We are given a n-digit number you have total of… Read More »

## Find a Number X whose sum with its digits is equal to NNovember 19, 2017

Given a positive number N. We need to find number(s) such that sum of digits of those numbers to themselves is equal to N. If… Read More »

## Count different numbers that can be generated such that there digits sum is equal to ‘n’

Given an positive integer n. Count the different numbers that can be generated using digits 1, 2, 3 and 4 such that digits sum is… Read More »

## Largest number with one swap allowedNovember 14, 2017

Given a positive integer, find the largest number that could be generated by swapping only two digits at most once. Examples: Input: 2736 Output :… Read More »

## Total no of 1’s in numbersNovember 13, 2017

Given an integer n, count the total number of digit 1 appearing in all positive integers less than or equal to n. Examples: Input :… Read More »

## Largest number with prime digitsNovember 12, 2017

Given a huge integer value n, find the largest integer value x such that x

## Largest smaller number possible using only one swap operationNovember 11, 2017

Given a non-negative number N in the form of string. The task is to apply at most one swap operation on the number N so… Read More »

## Program to check for ISBNNovember 10, 2017

An ISBN (International Standard Book Number) is a 10 digit number that is used to identify a book. The first nine digits of the ISBN… Read More »

## Program to check for Peterson numberNovember 9, 2017

A number is said to be a Peterson number if the sum of factorials of each digit of the number is equal to the number… Read More »

## Sum of digits of a given number to a given powerNovember 7, 2017

Given a number, we need to find the sum of all the digits of a number which we get after raising the number to a… Read More »

## Number of n digit numbers that do not contain 9

Given a number n, find how many n digit number can be formed that does not contain 9 as it’s digit. Examples: Input : 1… Read More »

## Recursive sum of digits of a number is prime or notNovember 3, 2017

Given a number n, we need to find the sum of each digits of the number till the number becomes a single digit. We need… Read More »

## Check if the product of digit sum and its reverse equals the number or notNovember 2, 2017

Given a number, check whether the product of digit sum and reverse of digit sum equals the number or not. Examples: Input : 1729 Output… Read More »

## Biggest integer which has maximum digit sum in range from 1 to nOctober 31, 2017

Given a number n, find a number in range from 1 to n such that its sum is maximum. If there are several such integers,… Read More »

## LCM of digits of a given numberOctober 23, 2017

Given a number n, find LCM of its digits. Examples: Input : 397 Output : 63 LCM of 3, 9 and 7 is 63. Input… Read More »