code: def get_int(self, input_string):
          
  
          if input_string in ('--ensemble_size', '--ncpu'):
  
              # was the flag set?
              try:
                  index = self.args.index(input_string) + 1
              except ValueError:
                  # it wasn't, so if it's required, exit
                  if input_string in self.required:
                      print("\n {flag} is required\n".format(flag=input_string))
                      print_short_help()
                      sys.exit(1)
                  # otherwise return the appropriate default
                  else:
                      return None
  
              # the flag was set, so check if a value was set, otherwise exit
              try:
                  if self.args[index] in self.flags:
                      print("\n {flag} was set but a value was not specified".format(flag=input_string))
                      print_short_help()
                      sys.exit(1)
              except IndexError:
                  print("\n {flag} was set but a value was not specified".format(flag=input_string))
                  print_short_help()
                  sys.exit(1)
  
              # a value was set, so check if its the correct type
              try:
                  value = int(self.args[index])
              except ValueError:
                  print("\n {flag} must be an integer".format(flag=input_string))
                  print_short_help()
                  sys.exit(1)
  
              # verify the value provided is not negative
              if value < 0:
                  print("\n {flag} must be an integer greater than 0".format(flag=input_string))
                  print_short_help()
                  sys.exit(1)
  
              # everything checks out, so return the value
              return value
docs: Return integer type user input