def encode(nucleotide):
    """
    Args:
        nucleotide: A string of one character
    Returns:
        An integer encoding the nucleotide, or -1 if not a valid nucleotide
    """
    # WRITE YOUR QUESTION 1 CODE HERE
    nucleotide_dict = {"A":0 , "C":1 , "G":2 , "T":3}
    if nucleotide in nucleotide_dict:
        return nucleotide_dict[nucleotide]
    else:
        return -1