// Numbas version: exam_results_page_options {"name": "Simon's copy of Number of combinations without replacement - lotto ticket,", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"ungrouped_variables": ["a", "b", "ans"], "preamble": {"js": "", "css": ""}, "variablesTest": {"condition": "", "maxRuns": 100}, "statement": "

In a lotto game a player buys a ticket and selects $\\var{b}$ numbers from a list of the numbers from $1$ to $\\var{a}$.

\n

Then $\\var{b}$ winning numbers are selected at random without replacement. If you have selected all $\\var{b}$ numbers correctly then you win the jackpot.

\n

How many tickets would you need to buy in order to be sure to win the jackpot?

", "metadata": {"description": "", "licence": "Creative Commons Attribution 4.0 International"}, "variable_groups": [], "parts": [{"variableReplacements": [], "extendBaseMarkingAlgorithm": true, "showCorrectAnswer": true, "customMarkingAlgorithm": "", "sortAnswers": false, "scripts": {}, "unitTests": [], "useCustomName": false, "variableReplacementStrategy": "originalfirst", "type": "gapfill", "customName": "", "showFeedbackIcon": true, "marks": 0, "gaps": [{"maxValue": "ans", "variableReplacements": [], "extendBaseMarkingAlgorithm": true, "showCorrectAnswer": true, "correctAnswerFraction": false, "correctAnswerStyle": "plain", "customMarkingAlgorithm": "", "showFractionHint": true, "scripts": {}, "notationStyles": ["plain", "en", "si-en"], "minValue": "ans", "unitTests": [], "useCustomName": false, "variableReplacementStrategy": "originalfirst", "type": "numberentry", "customName": "", "mustBeReduced": false, "showFeedbackIcon": true, "allowFractions": false, "marks": 2, "mustBeReducedPC": 0}], "prompt": "

Number of tickets = ?[[0]]

"}], "variables": {"a": {"name": "a", "group": "Ungrouped variables", "templateType": "anything", "description": "", "definition": "random(30..50)"}, "ans": {"name": "ans", "group": "Ungrouped variables", "templateType": "anything", "description": "", "definition": "comb(a,b)"}, "b": {"name": "b", "group": "Ungrouped variables", "templateType": "anything", "description": "", "definition": "random(4..7)"}}, "name": "Simon's copy of Number of combinations without replacement - lotto ticket,", "functions": {}, "extensions": [], "tags": [], "rulesets": {}, "advice": "

Each choice of $\\var{b}$ numbers results in a subset of the numbers $1$ to $\\var{a}$.

\n

In order to guarantee winning the jackpot, you must buy one ticket for every combination of $\\var{b}$ numbers out of the $\\var{a}$

\n

\n

The number of such possibilities is just the number of ways of choosing $\\var{b}$ items out of the $\\var{a}$, where order does not matter. i.e. \\[\\binom{\\var{a}}{\\var{b}}=\\var{ans}.\\] 

", "type": "question", "contributors": [{"name": "Newcastle University Mathematics and Statistics", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/697/"}, {"name": "Simon Thomas", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3148/"}]}]}], "contributors": [{"name": "Newcastle University Mathematics and Statistics", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/697/"}, {"name": "Simon Thomas", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3148/"}]}