or run

npx @tessl/cli init
Log in

Version

Files

docs

index.md
tile.json

rubric.jsonevals/scenario-7/

{
  "context": "This criteria evaluates how well the engineer uses lodash's random number generation capabilities to implement functions for generating random integers, floats, and selecting random items. The focus is on proper usage of _.random for number generation and _.sample for item selection.",
  "type": "weighted_checklist",
  "checklist": [
    {
      "name": "Uses _.random",
      "description": "Implementation uses lodash's _.random function to generate random numbers instead of implementing custom random logic",
      "max_score": 30
    },
    {
      "name": "Integer generation",
      "description": "getRandomInt correctly uses _.random to generate random integers, properly handling the inclusive bounds and optional second parameter",
      "max_score": 20
    },
    {
      "name": "Float generation",
      "description": "getRandomFloat correctly uses _.random with the floating parameter or appropriate configuration to generate random floating point numbers",
      "max_score": 20
    },
    {
      "name": "Uses _.sample",
      "description": "pickRandomItem uses lodash's _.sample function to select a random item from an array instead of manual random index selection",
      "max_score": 20
    },
    {
      "name": "Correct bounds handling",
      "description": "Implementation correctly handles edge cases like reversed bounds, single value ranges, and the optional second parameter as specified in the requirements",
      "max_score": 10
    }
  ]
}