// Numbas version: exam_results_page_options {"name": "Multiplication 2 digit by 2 digit", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"name": "Multiplication 2 digit by 2 digit", "tags": ["algorithms", "long multiplication", "multiplication", "times"], "metadata": {"description": "

Multiplication algorithm with integers

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

Write the following question down on paper and evaluate it without using a calculator. 

\n

If you are unsure of how to do a question, click on Show steps to see the full working. Then, once you understand how to do the question, click on Try another question like this one to start again. 

", "advice": "", "rulesets": {}, "extensions": [], "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"ab0t0": {"name": "ab0t0", "group": "2digit", "definition": "atop[0]*abot[0]", "description": "", "templateType": "anything", "can_override": false}, "asum1": {"name": "asum1", "group": "2digit", "definition": "abot[0]*atopnum", "description": "", "templateType": "anything", "can_override": false}, "ab0t1": {"name": "ab0t1", "group": "2digit", "definition": "abot[0]*atop[1]", "description": "", "templateType": "anything", "can_override": false}, "ab0t0carry": {"name": "ab0t0carry", "group": "2digit", "definition": "(ab0t0-ab0t0last)/10", "description": "", "templateType": "anything", "can_override": false}, "abot": {"name": "abot", "group": "2digit", "definition": "if(adigs[2]<>0,[adigs[3],adigs[2]],[adigs[2],adigs[3]])", "description": "

abot

", "templateType": "anything", "can_override": false}, "abotnum": {"name": "abotnum", "group": "2digit", "definition": "abot[1]*10+abot[0]", "description": "

botnum

", "templateType": "anything", "can_override": false}, "aansone": {"name": "aansone", "group": "2digit", "definition": "mod(aans,10)", "description": "", "templateType": "anything", "can_override": false}, "aansten": {"name": "aansten", "group": "2digit", "definition": "mod((aans-aansone)/10,10)", "description": "", "templateType": "anything", "can_override": false}, "ab1t0last": {"name": "ab1t0last", "group": "2digit", "definition": "mod(ab1t0,10)", "description": "", "templateType": "anything", "can_override": false}, "threedigit2": {"name": "threedigit2", "group": "Ungrouped variables", "definition": "random(101..999 except list(200..900#100) )", "description": "", "templateType": "anything", "can_override": false}, "twodigit3": {"name": "twodigit3", "group": "Ungrouped variables", "definition": "random(11..99 except list(20..90#10) )", "description": "", "templateType": "anything", "can_override": false}, "aans": {"name": "aans", "group": "2digit", "definition": "atopnum*abotnum", "description": "", "templateType": "anything", "can_override": false}, "ab1t1last": {"name": "ab1t1last", "group": "2digit", "definition": "mod(ab1t1pluscarry,10)", "description": "", "templateType": "anything", "can_override": false}, "ab1t1carry": {"name": "ab1t1carry", "group": "2digit", "definition": "(ab1t1pluscarry-ab1t1last)/10", "description": "", "templateType": "anything", "can_override": false}, "aanstho": {"name": "aanstho", "group": "2digit", "definition": "mod((aans-aansone-aansten*10-aanshun*100)/1000,10)", "description": "", "templateType": "anything", "can_override": false}, "aanshun": {"name": "aanshun", "group": "2digit", "definition": "mod((aans-aansone-aansten*10)/100,10)", "description": "", "templateType": "anything", "can_override": false}, "ab1t0": {"name": "ab1t0", "group": "2digit", "definition": "abot[1]*atop[0]", "description": "", "templateType": "anything", "can_override": false}, "twodigit1": {"name": "twodigit1", "group": "Ungrouped variables", "definition": "random(11..99 except list(20..90#10) )", "description": "", "templateType": "anything", "can_override": false}, "atopnum": {"name": "atopnum", "group": "2digit", "definition": "atop[1]*10+atop[0]", "description": "", "templateType": "anything", "can_override": false}, "atop": {"name": "atop", "group": "2digit", "definition": "if(adigs[0]<>0,[adigs[1],adigs[0]],[adigs[0],adigs[1]])", "description": "", "templateType": "anything", "can_override": false}, "ab1t1pluscarry": {"name": "ab1t1pluscarry", "group": "2digit", "definition": "ab1t1+ab1t0carry", "description": "", "templateType": "anything", "can_override": false}, "ab0t1carry": {"name": "ab0t1carry", "group": "2digit", "definition": "(ab0t1pluscarry-ab0t1last)/10", "description": "", "templateType": "anything", "can_override": false}, "threedigit3": {"name": "threedigit3", "group": "Ungrouped variables", "definition": "random(101..999 except list(200..900#100) )", "description": "", "templateType": "anything", "can_override": false}, "twodigit2": {"name": "twodigit2", "group": "Ungrouped variables", "definition": "random(11..99 except list(20..90#10) )", "description": "", "templateType": "anything", "can_override": false}, "asum2": {"name": "asum2", "group": "2digit", "definition": "10*abot[1]*atopnum", "description": "

sum2

", "templateType": "anything", "can_override": false}, "threedigit1": {"name": "threedigit1", "group": "Ungrouped variables", "definition": "random(101..999 except list(200..900#100) )", "description": "", "templateType": "anything", "can_override": false}, "ab0t1pluscarry": {"name": "ab0t1pluscarry", "group": "2digit", "definition": "ab0t1+ab0t0carry", "description": "

ab

", "templateType": "anything", "can_override": false}, "ab1t0carry": {"name": "ab1t0carry", "group": "2digit", "definition": "(ab1t0-ab1t0last)/10", "description": "", "templateType": "anything", "can_override": false}, "ab0t1last": {"name": "ab0t1last", "group": "2digit", "definition": "mod(ab0t1pluscarry,10)", "description": "", "templateType": "anything", "can_override": false}, "ab0t0last": {"name": "ab0t0last", "group": "2digit", "definition": "mod(ab0t0,10)", "description": "", "templateType": "anything", "can_override": false}, "adigs": {"name": "adigs", "group": "2digit", "definition": "shuffle(1..9)[0..4]", "description": "

we want distinct digits so it is easier to refer to digits unambiguously. 

", "templateType": "anything", "can_override": false}, "ab1t1": {"name": "ab1t1", "group": "2digit", "definition": "abot[1]*atop[1]", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "\n", "maxRuns": 100}, "ungrouped_variables": ["twodigit1", "twodigit2", "threedigit1", "threedigit2", "twodigit3", "threedigit3"], "variable_groups": [{"name": "2digit", "variables": ["adigs", "atop", "abot", "atopnum", "abotnum", "aans", "ab0t0", "ab0t0last", "ab0t0carry", "ab0t1", "ab0t1pluscarry", "ab0t1last", "ab0t1carry", "ab1t0", "ab1t0last", "ab1t0carry", "ab1t1", "ab1t1pluscarry", "ab1t1last", "ab1t1carry", "asum1", "asum2", "aansone", "aansten", "aanshun", "aanstho"]}], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": false, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

$\\var{atopnum}\\times\\var{abotnum} = $ [[0]]

", "stepsPenalty": "1", "steps": [{"type": "information", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

Generally we set up $\\var{atopnum}\\times\\var{abotnum}$ with the ones and tens columns lined up vertically:

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
$\\var{atop[1]}$$\\var{atop[0]}$$\\times$
$\\var{abot[1]}$$\\var{abot[0]}$
$\\phantom{0}$
\n

\n

We need to multiply each digit in the bottom number by each digit in the top number whilst respecting their place values.

\n

 

\n

We multiply the digits in the ones column, that is, $\\color{green}{\\var{abot[0]}\\times \\var{atop[0]}}$.

\n

Since this is just $\\var{ab0t0}$ we write $\\var{ab0t0}$ under the line in the ones column.

\n

Since this is $\\var{ab0t0}$ we write the $\\var{ab0t0last}$ under the line in the ones column and carry the $\\var{ab0t0carry}$ into the tens column to be dealt with in the next step.

\n

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
$\\overset{\\color{red}{\\var{ab0t0carry}}}{\\var{atop[1]}}$ $\\overset{\\phantom{1}}{\\var{atop[1]}}$ $\\color{green}{\\overset{\\phantom{1}}{\\var{atop[0]}}}$$\\times$
$\\var{abot[1]}$$\\color{green}{\\var{abot[0]}}$
$\\color{red}{\\var{ab0t0last}}$
\n

\n

\n

We now multiply diagonally, $\\color{green}{\\var{abot[0]}\\times \\var{atop[1]}}$. 

\n

This just gives us $\\var{ab0t1}$ so we write $\\var{ab0t1}$ under the line in the tens column.

\n

This gives us $\\var{ab0t1}$ so we write this under the line with the $\\var{ab0t1last}$ in the tens column.

\n

This gives us $\\var{ab0t1}$ but we have to add the $\\var{ab0t0carry}$ we carried earlier and so we write $\\var{ab0t1pluscarry}$ under the line with the $\\var{ab0t1last}$ in the tens column.

\n

This gives us $\\var{ab0t1}$ but we have to add the $\\var{ab0t0carry}$ we carried earlier and so we write $\\var{ab0t1pluscarry}$ under the line in the tens column.

\n

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
  $\\color{green}{\\overset{{\\var{ab0t0carry}}}{\\var{atop[1]}}}$ $\\color{green}{\\overset{\\phantom{1}}{\\var{atop[1]}}}$ $\\overset{\\phantom{1}}{\\var{atop[0]}}$$\\times$
 $\\var{abot[1]}$$\\color{green}{\\var{abot[0]}}$ 
$\\color{red}{\\var{ab0t1carry}}$ $\\phantom{0}$$\\color{red}{\\var{ab0t1last}}$${\\var{ab0t0last}}$ 
\n

\n

We are now finished with the digit $\\var{abot[0]}$ and move on to work with the $\\var{abot[1]}$ in the tens column. Since this is really a $\\var{abot[1]*10}$ we place a zero in the ones column on the next line to pad our numbers out. We also crossout or erase any carry marks that we have used.

\n

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
$\\overset{\\phantom{1}}{\\var{atop[1]}}$ $\\overset{\\phantom{1}}{\\var{atop[0]}}$$\\times$
$\\var{abot[1]}$$\\var{abot[0]}$
${\\var{ab0t1carry}}$$\\phantom{0}$${\\var{ab0t1last}}$${\\var{ab0t0last}}$
$\\color{red}0$
\n

\n

We now multiply along the other diagonal, that is, $\\color{green}{\\var{abot[1]}\\times\\var{atop[0]}}$.

\n

Since this is just $\\var{ab1t0}$ we write $\\var{ab1t0}$ under the line in the tens column.

\n

Since this is $\\var{ab1t0}$ we write the $\\var{ab1t0last}$ under the line in the tens column and carry the $\\var{ab1t0carry}$ into the tens column to be dealt with in the next step.

\n

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
$\\overset{\\color{red}{\\var{ab1t0carry}}}{\\var{atop[1]}}$ $\\overset{\\phantom{1}}{\\var{atop[1]}}$ $\\color{green}{\\overset{\\phantom{1}}{\\var{atop[0]}}}$$\\times$
$\\color{green}{\\var{abot[1]}}$$\\var{abot[0]}$
${\\var{ab0t1carry}}$$\\phantom{0}$${\\var{ab0t1last}}$${\\var{ab0t0last}}$
$\\color{red}{\\var{ab1t0last}}$${0}$
\n

\n

We now multiply the digits in the tens column, that is, $\\color{green}{\\var{abot[1]}\\times \\var{atop[1]}}$. 

\n

This just gives us $\\var{ab1t1}$ so we write $\\var{ab1t1}$ under the line in the hundreds column.

\n

This gives us $\\var{ab1t1}$ so we write this under the line with the $\\var{ab1t1last}$ in the hundreds column.

\n

This gives us $\\var{ab1t1}$ but we have to add the $\\var{ab1t0carry}$ we carried earlier and so we write $\\var{ab1t1pluscarry}$ under the line with the $\\var{ab1t1last}$ in the hundreds column.

\n

This gives us $\\var{ab1t1}$ but we have to add the $\\var{ab1t0carry}$ we carried earlier and so we write $\\var{ab1t1pluscarry}$ under the line in the hundreds column.

\n

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
$\\color{green}{\\overset{{\\var{ab1t0carry}}}{\\var{atop[1]}}}$ $\\color{green}{\\overset{\\phantom{1}}{\\var{atop[1]}}}$ $\\overset{\\phantom{1}}{\\var{atop[0]}}$$\\times$
$\\color{green}{\\var{abot[1]}}$$\\var{abot[0]}$
${\\var{ab0t1carry}}$$\\phantom{0}$${\\var{ab0t1last}}$${\\var{ab0t0last}}$
$\\color{red}{\\var{ab1t1carry}}$ $\\phantom{0}$$\\color{red}{\\var{ab1t1last}}$${\\var{ab1t0last}}$${0}$
\n

\n

We now add the two results to get the total, that is, $\\color{green}{\\var{asum1}+\\var{asum2}}$.

\n

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
$\\overset{{\\var{ab1t0carry}}}{\\var{atop[1]}}$ $\\overset{\\phantom{1}}{\\var{atop[1]}}$ $\\overset{\\phantom{1}}{\\var{atop[0]}}$$\\times$
$\\var{abot[1]}$$\\var{abot[0]}$
$\\color{green}{\\var{ab0t1carry}}$$\\phantom{0}$$\\color{green}{\\var{ab0t1last}}$$\\color{green}{\\var{ab0t0last}}$$+$
$\\color{green}{\\var{ab1t1carry}}$ $\\phantom{0}$$\\color{green}{\\var{ab1t1last}}$$\\color{green}{\\var{ab1t0last}}$$\\color{green}{0}$
$\\color{red}{\\var{aanstho}}$$\\phantom{0}$$\\color{red}{\\var{aanshun}}$$\\color{red}{\\var{aansten}}$$\\color{red}{\\var{aansone}}$
\n

\n

\n

The answer is therefore $\\var{aans}$.

"}], "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "aans", "maxValue": "aans", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always", "contributors": [{"name": "Ben Brawn", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/605/"}]}]}], "contributors": [{"name": "Ben Brawn", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/605/"}]}