测试评估
| 指标 | 结果 |
|---|---|
| Base 测试 | PASS |
| Plus 测试 | PASS |
| 代码长度 | 394 字符 |
模型生成的代码 (394 字符)
from collections import Counter
from typing import List, Dict, Any
def freq_count(lst: List[Any]) -> Dict[Any, int]:
"""
Returns the frequency of all elements in a list as a dictionary.
Args:
lst: A list of elements.
Returns:
A dictionary where keys are elements from the list and values are their frequencies.
"""
return dict(Counter(lst))
Base 失败测试用例
- 无失败测试
Plus 失败测试用例
- 无失败测试