// Numbas version: finer_feedback_settings {"name": "Roll a pair of dice - find probability at least one die shows a given number.", "extensions": ["stats"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"extensions": ["stats"], "preamble": {"css": "", "js": ""}, "statement": "

Two fair six-sided dice are rolled.

", "functions": {}, "advice": "\n \n \n

Let $A$ be the event that first dice shows a $\\var{number}$ $\\Rightarrow P(A)=\\frac{1}{6}$.

\n \n \n \n

Let $B$ be the event that second dice shows a $\\var{number}$ $\\Rightarrow P(B)=\\frac{1}{6}$.

\n \n \n \n

$A$ and $B$ are independent events so $P(A\\cap B) = P(A)\\times P(B)$.

\n \n \n \n

We want the probability $P(A \\cup B)$ of either $A$ or $B$ showing $\\var{number}$ and

\n \n \n \n

\\[\\begin{eqnarray*}\n \n P(A \\cup B) &=& P(A)+P(B)-P(A \\cap B)\\\\\n \n &=& P(A)+P(B)-P(A)P(B)\\\\\n \n &=&\\frac{1}{6}+ \\frac{1}{6}-\\frac{1}{36}\\\\\n \n &=& \\frac{11}{36}\n \n \\end{eqnarray*}\n \n \\]

\n \n \n ", "ungrouped_variables": ["number"], "type": "question", "parts": [{"showCorrectAnswer": true, "showFeedbackIcon": true, "type": "gapfill", "scripts": {}, "marks": 0, "customMarkingAlgorithm": "", "unitTests": [], "sortAnswers": false, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "gaps": [{"checkingAccuracy": 0.001, "showCorrectAnswer": true, "extendBaseMarkingAlgorithm": true, "scripts": {}, "customMarkingAlgorithm": "", "checkVariableNames": false, "answerSimplification": "std, fractionNumbers", "notallowed": {"strings": ["."], "message": "

Your answer has to be a fraction and not a decimal.

", "showStrings": false, "partialCredit": 0}, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "expectedVariableNames": [], "checkingType": "absdiff", "showFeedbackIcon": true, "type": "jme", "vsetRangePoints": 5, "failureRate": 1, "marks": 1, "unitTests": [], "showPreview": true, "vsetRange": [0, 1], "musthave": {"strings": ["/", 11, 36], "message": "

Input as a fraction.

", "showStrings": false, "partialCredit": 0}, "answer": "11/36"}], "extendBaseMarkingAlgorithm": true, "prompt": "

What is the probability of at least one die showing a $\\var{number}$?

\n

Probability = [[0]]

\n

Enter your answer as a fraction and not a decimal.

"}], "variable_groups": [], "variables": {"number": {"definition": "random(1..6)", "templateType": "anything", "name": "number", "description": "", "group": "Ungrouped variables"}}, "rulesets": {"std": ["all", "fractionNumbers", "!collectNumbers", "!noLeadingMinus"]}, "metadata": {"licence": "Creative Commons Attribution 4.0 International", "description": "

Rolling a pair of dice. Find probability that at least one die shows a given number.

"}, "variablesTest": {"maxRuns": 100, "condition": ""}, "name": "Roll a pair of dice - find probability at least one die shows a given number.", "tags": ["checked2015", "dice", "die", "elementary probability", "events", "independence", "independent events", "Probability", "probability", "probability dice", "statistics", "tested1"], "contributors": [{"name": "Bill Foster", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/6/"}, {"name": "Newcastle University Mathematics and Statistics", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/697/"}, {"name": "Xiaodan Leng", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2146/"}]}]}], "contributors": [{"name": "Bill Foster", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/6/"}, {"name": "Newcastle University Mathematics and Statistics", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/697/"}, {"name": "Xiaodan Leng", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2146/"}]}