Answers for "find largest digit in a number"

0

find largest digit in a number

int n, r, l = 0; //n=num, r= reminder , l= largest.
// this is the logic code only.
while (n>0)
{
r = n % 10;
if(l<r) {
l = r;
}
n = n / 10;
}
Posted by: Guest on January-25-2021

Code answers related to "find largest digit in a number"

Code answers related to "Shell/Bash"

Browse Popular Code Answers by Language