input: Write a function to generate a random string of given length using letters.
  assert len(generate_string(8)) == 8
  assert len(generate_string(12)) == 12
  assert isinstance(generate_string(5), str)
output: import string
  import random
  
  def generate_string(length):
      letters = string.ascii_letters
      return ''.join(random.choice(letters) for i in range(length))