0
function code in c++
input an integer and in which function should return number of digits in that number!
1 Answer
+ 1
Void length(int n)
{ int t, l;
while (n! =0)
{ t=n%10;
n=n/10;
l=l+1;
}
cout<<l;
}
This function will give you number of digits present in the entered number.



