write a program in bluej to input a string and display the count of whole no
Answers
Answered by
0
Answer:
public class NumberDigits {
public static void main(String num) {
int count = 0;
while(num != 0)
{
// num = num/10;
if (int (num)>=0&&int (num)<=9)
{ num /= 10;
++count;}
}
System.out.println("Number of digits: " + count);
}
}
Answered by
26
class string.........................
Similar questions