public class Test { public static void main(String[] args) { int n = 1234567890; String s = String.valueOf(n); int len = s.length(); System.out.println(len); } }