def get_dimensions(array):
    """
    Gets the dimensions for a two-dimensional array. The first dimension
    is simply the number of items in the list; the second dimension is the
    length of the shortest row. This ensures that any location (row, col)
    that is less than the resulting bounds will in fact map to a valid
    location in the array.

    RUNTIME: O(len(array))
    """
    rows = len(array)
    columns = 0

    # Gets the maximum for all the row lengths, essentially.
    for row in array:
        if len(row) > columns:
            columns = len(row)

    return (rows, columns)