测试评估
| 指标 | 结果 |
|---|---|
| Base 测试 | PASS |
| Plus 测试 | PASS |
| 代码长度 | 627 字符 |
模型生成的代码 (627 字符)
def filter_data(students, min_height, min_weight):
"""
Filter students whose height and weight are at least the specified minimums.
Args:
students (dict): Dictionary with student names as keys and (height, weight) tuples as values.
min_height (float): Minimum acceptable height.
min_weight (float): Minimum acceptable weight.
Returns:
dict: A dictionary containing only the students that meet both criteria.
"""
return {
name: (height, weight)
for name, (height, weight) in students.items()
if height >= min_height and weight >= min_weight
}
Base 失败测试用例
- 无失败测试
Plus 失败测试用例
- 无失败测试