def pad_word_array(word_array_to_pad, input_size):
    """
    ---------------------------------------------------------------------
    DESCRIPTION
    Pads the word array with ^ to reshape it to the network's input size,
    or trims it if necessary. Otherwise, leaves it unchanged.
    ---------------------------------------------------------------------
    PARAMETERS
    word_array_to_pad (string array): The word array to pad.
    input_size (integer): The input size the neural network expects.
    ---------------------------------------------------------------------
    """
    if len(word_array_to_pad) > input_size:
        return word_array_to_pad[0:input_size]
    elif len(word_array_to_pad) == input_size:
        return word_array_to_pad
    elif len(word_array_to_pad) < input_size:
        padded_word_array = word_array_to_pad
        for PadChar in range(input_size - len(word_array_to_pad)):
            padded_word_array.append("^")
        return padded_word_array