def crop_other_columns(table, required_columns):
    """This function removes the columns that are not in required_columns list
       This would help getting rid of columns that are not to be displayed.
    Args:
        table: Type-pandas.dataframe
        required_columns: Type-list of str

    Returns:
        Returns the table as a dataframe obj after
        removing the rest of the columns.
    """

    current_columns = table.columns
    for column in current_columns:
        if column not in required_columns:
            table = table.drop([column], axis=1)

    return table