code: def trim_shared_prefix(ref, alt):
      
      n_ref = len(ref)
      n_alt = len(alt)
      n_min = min(n_ref, n_alt)
      i = 0
      while i < n_min and ref[i] == alt[i]:
          i += 1
  
      # guaranteed that ref and alt agree on all the characters
      # up to i'th position, so it doesn't matter which one we pull
      # the prefix out of
      prefix = ref[:i]
      ref_suffix = ref[i:]
      alt_suffix = alt[i:]
      return ref_suffix, alt_suffix, prefix
docs: Sometimes mutations are given with a shared prefix between the reference
      and alternate strings. Examples: C>CT (nucleotides) or GYFP>G (amino acids).
  
      This function trims the common prefix and returns the disjoint ref
      and alt strings, along with the shared prefix.