skip column if either is a gap

def remove_gaps(A, B):
    """
    skip column if either is a gap
    """
    a_seq, b_seq = [], []
    for a, b in zip(list(A), list(B)):
        if a == '-' or a == '.' or b == '-' or b == '.':
            continue
        a_seq.append(a)
        b_seq.append(b)
    return ''.join(a_seq), ''.join(b_seq)