Use maxsize instead of maxint