title: I write the code in python to count digits of a number but It doesn't work for some numbers
body: <p>In order to count digits of a number I write this code in python:</p>
  
  <pre><code>a=int(input('number: '))
  count=0
  while a!=0:
      a=a//10
      count=count+1
  
  print('number has ',count,'digits') 
  </code></pre>
  
  <p>It works well for inputs like <code>13,1900,3222,....</code> But It give an error for numbers like: <code>3^21, 2^3,3*4,...</code></p>
  
  <p>It say:</p>
  
  <pre><code>ValueError: invalid literal for int() with base 10: '3**21'
  </code></pre>
  
  <p>3**21 is integer input So why it gives this erroer,and How Should I fix this? </p>