Mbpp/754

✅ 完美通过 Base: PASS Plus: PASS
测试评估
指标结果
Base 测试PASS
Plus 测试PASS
代码长度529 字符
模型生成的代码 (529 字符)
def extract_index_list(l1, l2, l3):
    """
    Returns a list of elements that are common to l1, l2, and l3 at the same index.
    An element is considered common if l1[i] == l2[i] == l3[i] for some index i.
    The iteration stops at the length of the shortest list.
    """
    # Determine the minimum length to avoid index out of range errors
    min_length = min(len(l1), len(l2), len(l3))
    result = []
    for i in range(min_length):
        if l1[i] == l2[i] == l3[i]:
            result.append(l1[i])
    return result
Base 失败测试用例
  • 无失败测试
Plus 失败测试用例
  • 无失败测试