def truncate(dataset: list, n: int):
    """
        Truncates dataset according to truncation parameter n.

        Args:  
            dataset: original dataset 
            n (int): truncation parameter
        Returns:
            truncated_dataset: truncated version of original dataset
    """
    truncated_dataset = []
    for item in dataset:
        truncated_dataset.append(item[:n])
    return truncated_dataset