#include<stdio.h>
#include<conio.h>
void main()
{
int n,d[10],i,k,s;
clrscr();
printf("enter the number..:");
scanf("%d",&n);
for(i=0,t=n;t>0;i++)
{
d[i]=t%10;
t=t/10;
}
k=i;
s=d[0];
for(i=1;i<k;i++)
{
if(d[i]<s)
s=d[i];
}
printf("\n The smallest digit is...%d",s);
getch();
}
160 and 192.
Count them unless the number has a recurring ending.
The tricky part is getting the individual digits. There are basically two ways to do this: 1) Convert the number to a string, and use string manipulation to get the individual digits. 2) Repeatedly divide the number by 10. The digit is the remainder (use the "%" operator). To actually get the highest digit, initially assume that the highest digit is zero (store this to a variable, called "maxDigit" or something similar). If you find a higher digit, replace maxDigit by that.
The greatest number is infinity.
Yes
syntax error
As 1 million is the lowest 7-digit number and also the square of one thousand, the number you seek is the square of 999, which I'm sure you can calculate!
find the diagonal method of two digit number and three digit number
Oh, what a delightful little puzzle we have here! To find a four-digit number that is divisible by both 8 and 9, we can look for a number that is divisible by their least common multiple, which is 72. So, let's find a multiple of 72 that is a four-digit number, like 1008. Such a harmonious number, don't you think?
It is easier to find the lowest common number, then getting the largest multiple of that that is under 10000. The LCM is 4680, x2 is 9360.
The lowest common multiple of 5 and 9 is 45 and 11 times 45 is 495 which is the greatest 3 digit number divisible by 5 and 9
The last digit is always the estimated digit in a number
"If the units digit and the hundreds digit of the number 513 were reversed..." 315 'find the sum of the original number and the new number." 513+315=828
It is 63.
first you look at the first number tell what that number is then you just find the first digit.
It is 99,899,999.
The units digit of a two digit number exceeds twice the tens digit by 1. Find the number if the sum of its digits is 10.