$b=$

0123456789

$a=$

c=

$\text{Überprüfen}$

$\text{Neuer Versuch}$

$\text{Neue Aufgabe}$

\colorbox{235, 231, 248}{\text{This text shows a hint for the student.\\
It is shown after the second wrong answer\
and is displayed during the third try.}}

No selection allowed for all input boxes

Selection allowed for all input boxes

\text{Welche Zahlen gehören in die leeren Felder?}

Fix position and allow selection for all text objects

Empty all input boxes

#EDEDED

\underline\text{Helper scripts for template}

\underline\text{Helper scripts for authors}

\colorbox{235, 231, 248}{\text{This hint is for typical misconceptions of\students. It is shown after any wrong answer\that shows the typical error.}}

$\textsf{Erklärung}$

\text\colorbox{#ebe7f8}{Jedes Dreieck stellt eine\
Rechnung dar.\\
Das Ergebnis jeder Rechnung steht\
an der unteren Spitze.}

\text{7    +    9     10    -    8}

\text{16        \cdot        2}

\text{32}

\textsf{Lösung:}

bInput = NaN
InputBox2 = Textfield(bInput)
randomNosb3 = Shuffle(Sequence[Random[2, 10], i, 1, 100])
randomNosb2 = Shuffle(Sequence[Random[2, 10], i, 1, 100])
isValid2: Length[KeepIf[¬(temp ∈ TextToUnicode[erlaubteZeichen]), temp, TextToUnicode[Text[InputBox2]]]] ≟ 0
count = 3
b3 = Element(randomNosb3, Mod[count, 100] + 1)
b2 = Element(randomNosb2, Mod[count, 100] + 1)
e22: (b2 * b3)
aInput = NaN
InputBox1 = Textfield(aInput)
randomNosb4 = Shuffle(Sequence[Random[10, 20], i, 1, 100])
randomNosb1 = Shuffle(Sequence[Random[2, 10], i, 1, 100])
b4 = Element(randomNosb4, Mod[count, 100] + 1)
b1 = Element(randomNosb1, Mod[count, 100] + 1)
e21: b1 + b4
isValid1: Length[KeepIf[¬(temp ∈ TextToUnicode[erlaubteZeichen]), temp, TextToUnicode[Text[InputBox1]]]] ≟ 0
cInput = NaN
InputBox3 = Textfield(cInput)
randomNosa4 = Shuffle(Sequence[Random[2, 5], i, 1, 100])
isValid3: Length[KeepIf[¬(temp ∈ TextToUnicode[erlaubteZeichen]), temp, TextToUnicode[Text[InputBox3]]]] ≟ 0
a4 = Element(randomNosa4, Mod[count, 100] + 1)
randomNosa2 = Shuffle(Sequence[Random[2, 10], i, 1, 100])
a2 = Element(randomNosa2, Mod[count, 100] + 1)
randomNosa1 = Shuffle(Sequence[Random[2, 15], i, 1, 100])
a1 = Element(randomNosa1, Mod[count, 100] + 1)
e12: a1 + a2
e13: (e12 * a4)
dInput = NaN
InputBox4 = Textfield(dInput)
isValid4: Length[KeepIf[¬(temp ∈ TextToUnicode[erlaubteZeichen]), temp, TextToUnicode[Text[InputBox4]]]] ≟ 0
eInput = NaN
InputBox5 = Textfield(eInput)
isValid5: Length[KeepIf[¬(temp ∈ TextToUnicode[erlaubteZeichen]), temp, TextToUnicode[Text[InputBox5]]]] ≟ 0
randomNose11 = Shuffle(Sequence[Random[2, 10], i, 1, 100])
e11 = Element(randomNose11, Mod[count, 100] + 1)
layout = Shuffle(Sequence[Random[1, 4], i, 1, 100])
randomNosd4 = Shuffle(Sequence[Random[2, 10], i, 1, 100])
randomNosd3 = Shuffle(Sequence[Random[2, 10], i, 1, 100])
randomNosd2 = Shuffle(Sequence[Random[2, 10], i, 1, 100])
randomNosd1 = Shuffle(Sequence[Random[2, 10], i, 1, 100])
lay = Element(layout, Mod[count, 100] + 1)
d4 = Element(randomNosd4, Mod[count, 100] + 1)
d3 = Element(randomNosd3, Mod[count, 100] + 1)
d2 = Element(randomNosd2, Mod[count, 100] + 1)
e42: (d2 * d3)
lay4cor2: bInput ≟ e42 ∧ isValid2
e43: d4 + e42
lay4cor3: cInput ≟ e43 ∧ isValid3
d1 = Element(randomNosd1, Mod[count, 100] + 1)
e41: (d1 * d4)
lay4cor1: aInput ≟ e41 ∧ isValid1
lay4cor: lay4cor1 ∧ lay4cor2 ∧ lay4cor3
lay1cor1: eInput ≟ e11 ∧ isValid5
lay1cor2: dInput ≟ e12 ∧ isValid4
lay1cor3: cInput ≟ e13 ∧ isValid3
lay1cor: lay1cor1 ∧ lay1cor2 ∧ lay1cor3
lay2cor2: bInput ≟ e22 ∧ isValid2
e23: b4 + e22
lay2cor3: cInput ≟ e23 ∧ isValid3
lay2cor1: aInput ≟ e21 ∧ isValid1
lay2cor: lay2cor1 ∧ lay2cor2 ∧ lay2cor3
randomNose32 = Shuffle(Sequence[Random[2, 10], i, 1, 100])
e32 = Element(randomNose32, Mod[count, 100] + 1)
lay3cor2: dInput ≟ e32 ∧ isValid4
randomNosc4 = Shuffle(Sequence[Random[2, 10], i, 1, 100])
c4 = Element(randomNosc4, Mod[count, 100] + 1)
e33: (e32 * c4)
lay3cor3: cInput ≟ e33 ∧ isValid3
randomNose31 = Shuffle(Sequence[Random[2, 10], i, 1, 100])
e31 = Element(randomNose31, Mod[count, 100] + 1)
lay3cor1: eInput ≟ e31 ∧ isValid5
lay3cor: lay3cor1 ∧ lay3cor2 ∧ lay3cor3
randomNosc2 = Shuffle(Sequence[Random[2, 25], i, 1, 100])
c2 = Element(randomNosc2, Mod[count, 100] + 1)
G = (-2.377614507882201, 5.095188716091623)
F = (-2.377614507882201, 4.545188716091623)
E = (-3.3676145078822013, 4.545188716091623)
D = (-3.3676145078822013, 5.095188716091623)
randomNosa3 = Shuffle(Sequence[Random[2, 5], i, 1, 100])
a3: e11 + a4
randomNosc1 = Shuffle(Sequence[Random[5, 8], i, 1, 100])
c1: c2 + e32
randomNosc3 = Shuffle(Sequence[Random[2, 9], i, 1, 100])
c3: (e31 * c4)
randomNos = Shuffle(Sequence[Random[1, 6], i, 1, 100])
auswahl = Element(randomNos, Mod[count, 100] + 1)
Blue = (-5.32, 4.5)
Green = (-5.28, 3.68)
Orange = (-5.2, 2.86)
Red = (-5.32, 2.04)
Purple = (-5.34, 1.12)
Gray = (-5.34, 0.32)
GrayDark = (-5.36, -0.7)
validate = false
showanswer = false
showsolution = false
attemptCount = 0
correctCount = 0
showButtonNew = false
showButtonTryAgain = false
showButtonValidate = true
showhint = false
correct = If(lay ≟ 1, lay1cor, If[lay ≟ 2, lay2cor, If[lay ≟ 3, lay3cor, lay4cor]])
showcorrecttext = false
questionCount = 2
PtopLeftCornerFeedback = (-1.9930565174501682, 2.6547051320631283)
PbottomRightCornerFeedback = (-0.973177416468549, 1.9611873433955849)
PtopRightCornerFeedback: (x(PbottomRightCornerFeedback), y(PtopLeftCornerFeedback))
PbottomLeftCornerFeedback: (x(PtopLeftCornerFeedback), y(PbottomRightCornerFeedback))
rectangleCorrect, ptopleftcornerfeedback, ptoprightcornerfeedback, pbottomrightcornerfeedback, pbottomleftcornerfeedback = Polygon(PtopLeftCornerFeedback, PtopRightCornerFeedback, PbottomRightCornerFeedback, PbottomLeftCornerFeedback)
showhinttypicalerror = false
isTypicalError: bInput ≟ aInput + 1
A = (-3.8424355205235505, 6.970498331201574)
B = (-2.931345290353329, 5.387981122694018)
poly1, f, g, h, C = Polygon(A, B, 3)
A_{1} = (-0.9867740377749119, 6.970498331201573)
B_{1} = (-0.07568380760469004, 5.3879811226940175)
poly1_{1}, f_{1}, g_{1}, h_{1}, C_{1} = Polygon(A_{1}, B_{1}, 3)
A_{2} = (-2.428203167162321, 4.332411056662311)
B_{2} = (-1.5171129369920984, 2.749893848154758)
poly1_{2}, f_{2}, g_{2}, h_{2}, C_{2} = Polygon(A_{2}, B_{2}, 3)
D_{1} = (-0.6119530251335622, 5.095188716091623)
E_{1} = (-0.6119530251335622, 4.545188716091623)
F_{1} = (0.3780469748664373, 4.545188716091623)
G_{1} = (0.3780469748664373, 5.095188716091623)
hinweis = false
A_{3} = (1.7151278582695118, 4.349149801159698)
B_{3} = (2.163872895994716, 3.5689374854243874)
poly1_{3}, f_{5}, g_{5}, h_{3}, C_{3} = Polygon(A_{3}, B_{3}, 3)
A_{4} = (2.9661795554736794, 4.33555141314661)
B_{4} = (3.4149245931988865, 3.555339097411299)
poly1_{4}, f_{6}, g_{6}, h_{4}, C_{4} = Polygon(A_{4}, B_{4}, 3)
A_{5} = (2.3134569308454176, 3.1116964919685985)
B_{5} = (2.7622019685706234, 2.331484176233291)
poly1_{5}, f_{7}, g_{7}, h_{5}, C_{5} = Polygon(A_{5}, B_{5}, 3)
D_{2} = (1.9267656341465536, 3.4619274605890036)
E_{2} = (1.9267682147537948, 3.134096719214662)
F_{2} = (2.4301356341465534, 3.134097460589003)
G_{2} = (2.4301356341465534, 3.4619274605890036)
q1_{2}, d_{2}, g_{8}, f_{8}, e_{2} = Polygon(D_{2}, G_{2}, F_{2}, E_{2})
D_{3} = (3.2050141073768996, 3.475525848602092)
E_{3} = (3.2050166879841413, 3.147695107227751)
F_{3} = (3.7083841073769013, 3.147695848602092)
G_{3} = (3.7083841073769013, 3.475525848602092)
q1_{3}, d_{3}, g_{9}, f_{9}, e_{3} = Polygon(D_{3}, G_{3}, F_{3}, E_{3})
D_{4} = (2.5386930947355473, 2.3060644794764413)
E_{4} = (2.538695675342789, 1.9782337381021002)
F_{4} = (3.042063094735549, 1.9782344794764413)
G_{4} = (3.042063094735549, 2.3060644794764413)
i = Segment(D_{4}, G_{4})
j = Segment(G_{4}, F_{4})
k = Segment(F_{4}, E_{4})
l = Segment(E_{4}, D_{4})
textCountCorrect: "\text{Richtig gelöste Aufgaben: " + (LaTeX[correctCount]) + "}"
lay1_1: "\text{" + (LaTeX[a1]) + "\:\:\:\:\:\:+\:\:\:\:\:\:" + (LaTeX[a2]) + "}"
lay1_2: "\text{" + (LaTeX[a3]) + "\:\:\:\:\:\:\:\:\:-}"
lay1: "\textsf{\cdot\:\:\:\:\:\:\:\:\:\:\:\:\:\:" + (LaTeX[a4]) + "}"
lay2: "\textsf{-\:\:\:\:\:\:" + (LaTeX[b1]) + "}"
lay2_1: "\textsf{" + (LaTeX[b2]) + "\:\:\:\:\:\:\:\:\:\cdot\:\:\:\:\:\:\:\:\:" + (LaTeX[b3]) + "}"
lay2_2: "\textsf{" + (LaTeX[b4]) + "\:\:\:\:\:\:\:\:\:\:\:\:+}"
lay3: "\textsf{" + (LaTeX[c1]) + "\:\:\:\:\:\:\:-\:\:\:\:\:\:\:" + (LaTeX[c2]) + "}"
lay3_1: "\textsf{" + (LaTeX[c3]) + "\:\:\:\:\:\:\::}"
lay3_2: "\textsf{\cdot\:\:\:\:\:\:\:\:\:\:\:\:\:\:" + (LaTeX[c4]) + "}"
lay4: "\textsf{:\:\:\:\:\:\:\:\:" + (LaTeX[d1]) + ""
lay4_1: "\textsf{" + (LaTeX[d2]) + "\:\:\:\:\:\:\:\:\cdot\:\:\:\:\:\:\:\:" + (LaTeX[d3]) + "}"
lay4_2: "\textsf{" + (LaTeX[d4]) + "\:\:\:\:\:\:\:\:\:\:\:\:\:\:+"
sol1: "\textsf{(" + (LaTeX[a1]) + " + " + (LaTeX[a2]) + ") \cdot (" + (LaTeX[a3]) + " - " + (LaTeX[e11]) + ") = " + (LaTeX[e12]) + " \cdot " + (LaTeX[a4]) + " = " + (LaTeX[e13]) + ""
sol2: "\textsf{(" + (LaTeX[e21]) + " - " + (LaTeX[b1]) + ") + (" + (LaTeX[b2]) + " \cdot " + (LaTeX[b3]) + ") = " + (LaTeX[b4]) + " + " + (LaTeX[e22]) + " = " + (LaTeX[e23]) + ""
sol3: "\textsf{(" + (LaTeX[c1]) + " - " + (LaTeX[c2]) + ") \cdot (" + (LaTeX[c3]) + " : " + (LaTeX[e31]) + ") = " + (LaTeX[e32]) + " \cdot " + (LaTeX[c4]) + " = " + (LaTeX[e33]) + ""
sol4: "\textsf{(" + (LaTeX[e41]) + " : " + (LaTeX[d1]) + ") + (" + (LaTeX[d2]) + " \cdot " + (LaTeX[d3]) + ") = " + (LaTeX[d4]) + " + " + (LaTeX[e42]) + " = " + (LaTeX[e43]) + ""
PtopLeftCornerFeedback_{1} = (-3.3936904827983096, 5.1568085264715)
PbottomRightCornerFeedback_{1} = (-2.4554017098952228, 4.4224955737646905)
PtopRightCornerFeedback_{1}: (x(PbottomRightCornerFeedback_{1}), y(PtopLeftCornerFeedback_{1}))
PbottomLeftCornerFeedback_{1}: (x(PtopLeftCornerFeedback_{1}), y(PbottomRightCornerFeedback_{1}))
rectangleCorrect_{1}, ptopleftcornerfeedback_{1}, ptoprightcornerfeedback_{1}, pbottomrightcornerfeedback_{1}, pbottomleftcornerfeedback_{1} = Polygon(PtopLeftCornerFeedback_{1}, PtopRightCornerFeedback_{1}, PbottomRightCornerFeedback_{1}, PbottomLeftCornerFeedback_{1})
PtopLeftCornerFeedback_{2} = (-0.5788241640889389, 5.279194018589301)
PbottomRightCornerFeedback_{2} = (0.386661384840326, 4.544881065882492)
PtopRightCornerFeedback_{2}: (x(PbottomRightCornerFeedback_{2}), y(PtopLeftCornerFeedback_{2}))
PbottomLeftCornerFeedback_{2}: (x(PtopLeftCornerFeedback_{2}), y(PbottomRightCornerFeedback_{2}))
rectangleCorrect_{2}, ptopleftcornerfeedback_{2}, ptoprightcornerfeedback_{2}, pbottomrightcornerfeedback_{2}, pbottomleftcornerfeedback_{2} = Polygon(PtopLeftCornerFeedback_{2}, PtopRightCornerFeedback_{2}, PbottomRightCornerFeedback_{2}, PbottomLeftCornerFeedback_{2})
PtopLeftCornerFeedback_{3} = (0.2098823406702084, 7.672510308892962)
PbottomRightCornerFeedback_{3} = (1.148171113573296, 6.911000580159975)
PtopRightCornerFeedback_{3}: (x(PbottomRightCornerFeedback_{3}), y(PtopLeftCornerFeedback_{3}))
PbottomLeftCornerFeedback_{3}: (x(PtopLeftCornerFeedback_{3}), y(PbottomRightCornerFeedback_{3}))
rectangleCorrect_{3}, ptopleftcornerfeedback_{3}, ptoprightcornerfeedback_{3}, pbottomrightcornerfeedback_{3}, pbottomleftcornerfeedback_{3} = Polygon(PtopLeftCornerFeedback_{3}, PtopRightCornerFeedback_{3}, PbottomRightCornerFeedback_{3}, PbottomLeftCornerFeedback_{3})
PtopLeftCornerFeedback_{4} = (-4.2503889276229, 7.699707084919139)
PbottomRightCornerFeedback_{4} = (-3.3121001547198143, 6.978992520225419)
PtopRightCornerFeedback_{4}: (x(PbottomRightCornerFeedback_{4}), y(PtopLeftCornerFeedback_{4}))
PbottomLeftCornerFeedback_{4}: (x(PtopLeftCornerFeedback_{4}), y(PbottomRightCornerFeedback_{4}))
rectangleCorrect_{4}, ptopleftcornerfeedback_{4}, ptoprightcornerfeedback_{4}, pbottomrightcornerfeedback_{4}, pbottomleftcornerfeedback_{4} = Polygon(PtopLeftCornerFeedback_{4}, PtopRightCornerFeedback_{4}, PbottomRightCornerFeedback_{4}, PbottomLeftCornerFeedback_{4})
H = (2.5366178454790287, 5.501066432332453)
I = (3.0655438234188144, 6.43505699970186)
poly2, m, n, p, J = Polygon(H, I, 3)
H_{1} = (3.950850198840259, 5.501066432332453)
I_{1} = (4.479776176780043, 6.43505699970186)
poly2_{1}, m_{1}, n_{1}, p_{1}, J_{1} = Polygon(H_{1}, I_{1}, 3)
H_{2} = (3.2029388581203775, 4.086834078971199)
I_{2} = (3.7318648360601614, 5.020824646340606)
poly2_{2}, m_{2}, n_{2}, p_{2}, J_{2} = Polygon(H_{2}, I_{2}, 3)
text19: "\textsf{" + (LaTeX[a1]) + "  +  " + (LaTeX[a2]) + "}"
text20: "\textsf{" + (LaTeX[a3]) + "  -  \textcolor{#006758}{" + (LaTeX[e11]) + "}}"
text23: "\textsf{\textcolor{#006758}{" + (LaTeX[e21]) + "}  -  " + (LaTeX[b1]) + "}"
text24: "\textsf{" + (LaTeX[b2]) + "   \cdot   " + (LaTeX[b3]) + "}"
text25: "\textsf{" + (LaTeX[b4]) + "     +     \textcolor{#006758}{" + (LaTeX[e22]) + "}}"
text26: "\textsf{\textcolor{#006758}{" + (LaTeX[e23]) + "}}"
text27: "\textsf{" + (LaTeX[c1]) + "   -   " + (LaTeX[c2]) + ""
text28: "\textsf{" + (LaTeX[c3]) + "   :   \textcolor{#006758}{" + (LaTeX[e31]) + "}}"
text29: "\textsf{\textcolor{#006758}{" + (LaTeX[e32]) + "}      \cdot      " + (LaTeX[c4]) + "}"
text30: "\textsf{\textcolor{#006758}{" + (LaTeX[e33]) + "}}"
text31: "\textsf{\textcolor{#006758}{" + (LaTeX[e41]) + "}   :   " + (LaTeX[d1]) + "}"
text32: "\textsf{" + (LaTeX[d2]) + "   \cdot   " + (LaTeX[d3]) + "}"
text33: "\textsf{" + (LaTeX[d4]) + "     +     \textcolor{#006758}{" + (LaTeX[e42]) + "}}"
text34: "\textsf{\textcolor{#006758}{" + (LaTeX[e43]) + "}}"
text21: "\textsf{\textcolor{#006758}{" + (LaTeX[e12]) + "}      \cdot      " + (LaTeX[a4]) + "}"
text22: "\textsf{\textcolor{#006758}{" + (LaTeX[e13]) + "}}"
correctText: "\text{" + (LaTeX[If[lay ≟ 1 ∧ (¬correct) ∧ (lay1cor1 ∨ lay1cor2 ∨ lay1cor3), "✘ Teilweise richtig", If[lay ≟ 2 ∧ (¬correct) ∧ (lay2cor1 ∨ lay2cor2 ∨ lay2cor3), "✘ Teilweise richtig", If[lay ≟ 3 ∧ (¬correct) ∧ (lay3cor1 ∨ lay3cor2 ∨ lay3cor3), "✘ Teilweise richtig", If[lay ≟ 4 ∧ (¬correct) ∧ (lay4cor1 ∨ lay4cor2 ∨ lay4cor3), "✘ Teilweise richtig", If[correct, "✓ Richtig", "✘ Falsch"]]]]]]) + "}"