def get_int_len(_int):
 power = 1
 while True:
  if (_int == 0):
   return 0
  elif (_int < (10 ** power)):
   return power
  power += 1

def get_int_len ( _int ) : power = 1 while True : if ( _int == 0 ) : return 0 elif ( _int < ( 10 ** power ) ) : return power power += 1
find the number of digits of an int given an integer .