docs
evals
scenario-1
scenario-10
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
{
"context": "This criteria evaluates how well the engineer uses lodash's minBy function to find minimum values in collections based on different iteratee functions. The focus is on proper usage of lodash's iteratee-based minimum finding capabilities.",
"type": "weighted_checklist",
"checklist": [
{
"name": "Uses minBy function",
"description": "Uses lodash's minBy function instead of manual loops or reduce to find minimum values in all three functions (findCheapestProduct, findMinRatingProduct, findShortestNameProduct)",
"max_score": 45
},
{
"name": "Property iteratee",
"description": "Uses property name string as iteratee (e.g., 'price' or 'rating') in findCheapestProduct and findMinRatingProduct functions, leveraging lodash's iteratee shorthand",
"max_score": 25
},
{
"name": "Function iteratee",
"description": "Uses a function as iteratee in findShortestNameProduct to compute name length (e.g., product => product.name.length or using lodash property shorthand)",
"max_score": 20
},
{
"name": "Correct return values",
"description": "All functions correctly return the entire product object (not just the minimum value) and handle empty arrays by returning undefined, matching minBy's behavior",
"max_score": 10
}
]
}