input: from typing import List
  
  
  def generate_random_string(length: int) -> str:
      """ Generate a random string of specified length made of uppercase letters and numbers.
      >>> generate_random_string(8) in [''.join(random.choice(string.ascii_uppercase + string.digits) for i in range(8)) for _ in range(1000)]
      True
      >>> generate_random_string(8) != generate_random_string(8)
      True
      """
      import string
      import random
  
      chars = string.ascii_uppercase + string.digits
      return ''.join(random.choice(chars) for i in range(length))
output:     import string
      import random
  
      chars = string.ascii_uppercase + string.digits
      return ''.join(random.choice(chars) for i in range(length))