input: from typing import List
  
  def interpret_melody(melody_string: str) -> List[int]:
      """ This function accepts a string that encodes musical notes using a specific ASCII representation.
      The goal is to analyze this string and produce a list of integers that specify the number of beats each note lasts.
  
      Legend:
      'o' - full note, lasts four beats
      'o|' - half note, lasts two beats
      '.|' - quarter note, lasts one beat
  
      >>> interpret_melody('o o| .| o| o| .| .| .| .| o o')
      [4, 2, 1, 2, 2, 1, 1, 1, 1, 4, 4]
      """
output:     notes = melody_string.split()
      beats = []
      
      for note in notes:
          if note == 'o':
              beats.append(4)
          elif note == 'o|':
              beats.append(2)
          elif note == '.|':
              beats.append(1)
      
      return beats