input: from typing import List
  
  def generate_random_array(size: int, lower_bound: int, upper_bound: int) -> List[int]:
      """ Generate an array of random integers within a specified range
      >>> generate_random_array(3, 1, 20)
      [5, 12, 9]
      >>> generate_random_array(5, 10, 50)
      [15, 23, 44, 18, 36]
      """
output:     import random
      return [random.randint(lower_bound, upper_bound) for _ in range(size)]