def increment_array_and_count(tag_name, count, word):
    """
    Increment a count within a dictionary or add a new count if necessary
    """
    tag = tag_name
    try:
        count[word] += 1
    except:
        count[word] = 1
    return tag, count