1: Point, 2: Segment, 3: Ray, 4: Line

#4D4D4D

$\text{Check}$

$\text{NUEVO}$

Fix position and allow selection for all text objects

Empty all input boxes

\text{This is the answer.}

$a=\vphantom{b}$

$b=$

Reset app

#006758

#B00020

#252525

#757575

#949494

#E44461

#DA2570

#E66B9E

#3A6ED6

#5991FF

#008475

#0F8538

#00a83c

#5145A8

#6557D2

#8575FF

#903D14

#BD6C43

#C75000

#E07415

\text{Introduce el nombre tal como lo pronunciarías\
en voz alta. Si utilizas un símbolo, elígelo \cuidadosamente y colócalo en el lugar correcto.}

#eeeeee

#2E006758

#2EB00020

\text{Drag to start}

\text{Arrastra las piezas para nombrar el objeto \resaltado en la figura.}

organize

text13

alternate

hei: 1
randomList1 = Shuffle(Flatten[Sequence[Sequence[4], ii, 1, 4]])
randomList2 = Shuffle(Sequence[76])
randomP1 = Shuffle(Sequence[5])
countQuestion = 0
numP1 = Element(randomP1, Mod[countQuestion, Length[randomP1]] + 1)
PointsAll = Shuffle(Flatten[Sequence[Sequence[(ii, jj), ii, 0, 8], jj, 0, 8]])
randomP2 = Shuffle(Sequence[5] \ {numP1})
wid: 4
droparea = Polygon({(9.4, 5.11 - 1.5), (18.3, 5.11 - 1.5), (18.3, 5.11), (9.4, 5.11)} + (0, 0.5))
TargetPointsDown = Sequence((9.4 + (wid / 4 * ii), y(Vertex[droparea, 1])), ii, 0, 8)
TargetPointsUp = Sequence((9.4 + ii, y(TargetPointsDown(1)) + hei), ii, 0, 7)
MoveBox12 = (16.4, 6.050000000000001)
box12, e_1, a_1, b_1, f_2 = Polygon(MoveBox12, MoveBox12 + (wid / 2, 0), MoveBox12 + (wid / 2, hei / 2), MoveBox12 + (0, hei / 2))
box12InReg: true ∈ Sequence[IsInRegion[Vertex[box12, ii], droparea], ii, 1, 4]
MoveBox11 = (12.9, 6.050000000000001)
box11, d_1, r_1, s_1, t_1 = Polygon(MoveBox11, MoveBox11 + (wid / 2, 0), MoveBox11 + (wid / 2, hei / 2), MoveBox11 + (0, hei / 2))
box11InReg: true ∈ Sequence[IsInRegion[Vertex[box11, ii], droparea], ii, 1, 4]
MoveBox10 = (9.4, 6.050000000000001)
box10, c_1, n_1, p_1, q_1 = Polygon(MoveBox10, MoveBox10 + (wid / 2, 0), MoveBox10 + (wid / 2, hei / 2), MoveBox10 + (0, hei / 2))
box10InReg: true ∈ Sequence[IsInRegion[Vertex[box10, ii], droparea], ii, 1, 4]
symbolUsed = Mod(IndexOf[true, {box10InReg, box11InReg, box12InReg, true}], 4)
symbolPos = If(symbolUsed ≟ 0, 0, IndexOf[Element[{MoveBox10, MoveBox11, MoveBox12}, symbolUsed], TargetPointsUp])
InDropArea: {100}
inputCurrent = Flatten({{symbolUsed, symbolPos}, InDropArea})
IsLine: Length[inputCurrent] ≟ 6 ∧ Take[inputCurrent, 1, 4] ≟ {0, 0, 100, 4} ∧ inputCurrent(5) ≥ 5 ∧ inputCurrent(6) ≥ 5 ∨ Length[inputCurrent] ≟ 6 ∧ Take[inputCurrent, 1, 4] ≟ {3, 5, 100, 4} ∧ inputCurrent(5) ≥ 5 ∧ inputCurrent(6) ≥ 5 ∨ Length[inputCurrent] ≟ 5 ∧ Take[inputCurrent, 1, 3] ≟ {3, 1, 100} ∧ inputCurrent(4) ≥ 5 ∧ inputCurrent(5) ≥ 5
IsRay: Length[inputCurrent] ≟ 6 ∧ Take[inputCurrent, 1, 4] ≟ {0, 0, 100, 3} ∧ inputCurrent(5) ≥ 5 ∧ inputCurrent(6) ≥ 5 ∨ Length[inputCurrent] ≟ 6 ∧ Take[inputCurrent, 1, 4] ≟ {2, 5, 100, 3} ∧ inputCurrent(5) ≥ 5 ∧ inputCurrent(6) ≥ 5 ∨ Length[inputCurrent] ≟ 5 ∧ Take[inputCurrent, 1, 3] ≟ {2, 1, 100} ∧ inputCurrent(4) ≥ 5 ∧ inputCurrent(5) ≥ 5
IsSegment: Length[inputCurrent] ≟ 6 ∧ Take[inputCurrent, 1, 4] ≟ {0, 0, 100, 2} ∧ inputCurrent(5) ≥ 5 ∧ inputCurrent(6) ≥ 5 ∨ Length[inputCurrent] ≟ 6 ∧ Take[inputCurrent, 1, 4] ≟ {1, 5, 100, 2} ∧ inputCurrent(5) ≥ 5 ∧ inputCurrent(6) ≥ 5 ∨ Length[inputCurrent] ≟ 5 ∧ Take[inputCurrent, 1, 3] ≟ {1, 1, 100} ∧ inputCurrent(4) ≥ 5 ∧ inputCurrent(5) ≥ 5
IsPoint: Length[inputCurrent] ≟ 5 ∧ Take[inputCurrent, 1, 4] ≟ {0, 0, 100, 1} ∧ inputCurrent(5) ≥ 5 ∨ Length[inputCurrent] ≟ 4 ∧ Take[inputCurrent, 1, 3] ≟ {0, 0, 100} ∧ inputCurrent(4) ≥ 5
numP2 = Element(randomP2, Mod[countQuestion, Length[randomP2]] + 1)
randomNum2 = Element(randomList2, Mod[countQuestion, Length[randomList2]] + 1)
PointsToShow = Take(PointsAll, randomNum2, randomNum2 + 4)
lineComplete = Line(PointsToShow(numP1), PointsToShow(numP2))
slp = Slope(lineComplete)
o = If(¬Defined[slp], y ≤ y(PointsToShow(numP1)), If[slp ≟ 0, x ≤ x(PointsToShow(numP1)), y ≤ (-1 / slp * (x - x(PointsToShow(numP1)))) + y(PointsToShow(numP1))])
colinears = KeepIf(AreCollinear[PointsToShow(numP1), PointsToShow(numP2), PP], PP, PointsToShow)
colinearsAndSameSide = KeepIf(IsInRegion[PP, o] ≟ IsInRegion[PointsToShow(numP2), o], PP, colinears)
forRaysIndex: Zip[IndexOf[PP, PointsToShow], PP, colinearsAndSameSide] + 4
PointsToShowF: PointsToShow
colinearsIndex: Zip[IndexOf[PP, PointsToShowF], PP, colinears] + 4
correctForLines = Join(Sequence[Sequence[{colinearsIndex(ii), colinearsIndex(jj)}, ii, 1, Length[colinearsIndex]], jj, 1, Length[colinearsIndex]])
correctPoint: {{0, 0, 100, 1, 4 + numP1}, {0, 0, 100, 4 + numP1}}
correctLine = Join(Zip[Zip[Flatten[{LL, MM}], LL, {{0, 0, 100, 4}, {3, 1, 100}, {3, 5, 100, 4}}], MM, correctForLines])
correctRay = Join(Zip[Zip[Append[LL, kk], LL, {{0, 0, 100, 3, numP1 + 4}, {2, 5, 100, 3, numP1 + 4}, {2, 1, 100, numP1 + 4}}], kk, forRaysIndex])
correctSegment: {{0, 0, 100, 2, 4 + numP1, 4 + numP2}, {0, 0, 100, 2, 4 + numP2, 4 + numP1}, {1, 5, 100, 2, 4 + numP1, 4 + numP2}, {1, 5, 100, 2, 4 + numP2, 4 + numP1}, {1, 1, 100, 4 + numP1, 4 + numP2}, {1, 1, 100, 4 + numP2, 4 + numP1}}
randomNum1 = Element(randomList1, Mod[countQuestion, Length[randomList1]] + 1)
MoveBox2 = (14.4, 9.15)
box2, movebox2, i, j, k = Polygon(MoveBox2, MoveBox2 + (wid, 0), MoveBox2 + (wid, hei), MoveBox2 + (0, hei))
Expected4: IndexOf[PointsToShow(numP2), PointsToShowF] + 4
Expected3: IndexOf[PointsToShow(numP1), PointsToShowF] + 4
expected = Element({correctPoint, correctSegment, correctRay, correctLine}, randomNum1)
labelsdown: Slope[lineComplete] ≥ 0
Positions = Flatten({Sequence[Sequence[(9.4 + (ii * If[jj ≤ 1, 5, 2]), 9.65 - hei - (1.2 * jj) + 0.5), ii, 0, If[jj ≤ 1, 1, 4]], jj, 0, 2], Sequence[(9.4 + (ii * 3.5), 9.65 - hei - (1.2 * 3) + hei / 2 + 0.5), ii, 0, 2], TargetPointsDown})
onboarding = false
inputSaved: {0, 0, 100}
input2 = NaN
input1 = NaN
A = (3.4347091871177713, 5.572495645015256)
correct1: input1 ≟ randomNum1
validate = false
showanswer = false
showsolution = false
tries = 0
countCorrect = 0
showhint = false
InputBox1 = Textfield(input1)
InputBox2 = Textfield(input2)
correct2: input2 ≟ randomNum2
correct: inputCurrent ∈ expected
showbuttons = true
typicalError1: 0
typicalError2: 0
helpTextHintTypicalError: "\text{" + (LaTeX[If[IsPoint ∨ IsRay ∨ IsSegment ∨ IsLine, "Compara el objeto dado con el que\\tú nombraste: ", "Revisa que el nombre esté en el orden\\correcto. "]]) + "}"
showhinttypicalerror = false
pixelsRight: 16
pixelsLeft: 16
pixelsBottom: 16
pixelsTop: 24
borderBox = Polygon(Zip[PixelsToPoint[Corner[1], Corner[3], Corner[5], A], A, {(pixelsLeft, pixelsTop), (pixelsLeft, y(Corner[5]) - pixelsBottom), Corner[5] - (pixelsRight, pixelsBottom), (x(Corner[5]) - pixelsRight, pixelsTop)}])
layoutY: 277
enableInput: tries < 3 ∧ (¬(validate ∧ correct))
layoutX: 404
layoutAppSize = Corner(5)
enableBtnValidate: inputCurrent ≠ inputSaved
B = (4.1638207264560645, 6.136241785204535)
displaySegment = Segment(A, B)
StartA = (3.4347091871177713, 5.572495645015256)
StartB = (4.1638207264560645, 6.136241785204535)
pulsingSpeed = 8
pulsing = 0 (slider from 0 to 1, step 0.1)
haloPixels: (pulsing * 7)
count = 2
onboardingCase: 1
onboardingX: 337
onboardingY: 150
OnboardingTextOffset = onboardingTextOffset(Corner[onboardingText, 1], Corner[onboardingText, 3], onboardingCase, Corner[1], Corner[3], Corner[5])
onboardingDisplayText: "" + (LaTeX[onboardingText]) + ""
useOnboarding = false
layoutCase: 1
layoutHintSolnY: layoutY + Element[{56, 88}, layoutCase]
layoutHintSolnX: layoutX - 5
layoutFeedbackX: layoutX + Element[{If[correct ∨ tries ≟ 3, -5, 158], -5}, layoutCase]
layoutFeedbackY: layoutY + Element[{If[correct, 6, 1], If[correct, 6, If[tries ≟ 3, 1, 51]]}, layoutCase]
q1 = Polygon({(-0.5, -0.5), (8.5, -0.5), (8.5, 8.5), (-0.5, 8.5)})
Cor1 = (-0.91, -2.01)
Cor3 = (19.45, 10.74)
labelsPoints = Zip(Text[TT, PP + (0.1, 0.1), true, true, 1, If[labelsdown, -1, 1]], TT, {"A", "B", "C", "D", "E"}, PP, PointsToShowF)
SinglePoint = Element(PointsToShow, numP1)
labelSinglePoint = Element(labelsPoints, numP1)
segmentCase2 = Segment(PointsToShow(numP1), PointsToShow(numP2))
rayComplete = Ray(PointsToShow(numP1), PointsToShow(numP2))
rayInWindow = IntersectPath(rayComplete, q1)
lineInWindow = IntersectPath(lineComplete, q1)
l1: {"Punto", "Segmento", "Semirrecta", "Recta", "A", "B", "C", "D", "E"}
MoveBox1 = (9.4, 9.15)
box1, movebox1, f, g, h = Polygon(MoveBox1, MoveBox1 + (wid, 0), MoveBox1 + (wid, hei), MoveBox1 + (0, hei))
MoveBox3 = (9.4, 7.95)
MoveBox4 = (14.4, 7.95)
box3, movebox3, l, m, n = Polygon(MoveBox3, MoveBox3 + (wid, 0), MoveBox3 + (wid, hei), MoveBox3 + (0, hei))
box4, movebox4, p, q, r = Polygon(MoveBox4, MoveBox4 + (wid, 0), MoveBox4 + (wid, hei), MoveBox4 + (0, hei))
box1InMove: ¬Defined[IndexOf[MoveBox1, Positions]]
box2InMove: ¬Defined[IndexOf[MoveBox2, Positions]]
box3InMove: ¬Defined[IndexOf[MoveBox3, Positions]]
box4InMove: ¬Defined[IndexOf[MoveBox4, Positions]]
text1 = Text(l1(1), MoveBox1 + (wid, hei) / 2, true, true, 0, 0)
text2 = Text(l1(2), MoveBox2 + (wid, hei) / 2, true, true, 0, 0)
text3 = Text(l1(3), MoveBox3 + (wid, hei) / 2, true, true, 0, 0)
text4 = Text(l1(4), MoveBox4 + (wid, hei) / 2, true, true, 0, 0)
MoveBox5 = (9.4, 6.75)
MoveBox6 = (11.4, 6.75)
MoveBox7 = (13.4, 6.75)
MoveBox8 = (15.4, 6.75)
MoveBox9 = (17.4, 6.75)
box5, movebox5, s, t, a = Polygon(MoveBox5, MoveBox5 + (wid / 4, 0), MoveBox5 + (wid / 4, hei), MoveBox5 + (0, hei))
box6, movebox6, b, c, d = Polygon(MoveBox6, MoveBox6 + (wid / 4, 0), MoveBox6 + (wid / 4, hei), MoveBox6 + (0, hei))
box7, movebox7, e, f_1, g_1 = Polygon(MoveBox7, MoveBox7 + (wid / 4, 0), MoveBox7 + (wid / 4, hei), MoveBox7 + (0, hei))
box8, movebox8, h_1, i_1, j_1 = Polygon(MoveBox8, MoveBox8 + (wid / 4, 0), MoveBox8 + (wid / 4, hei), MoveBox8 + (0, hei))
box9, movebox9, k_1, l_1, m_1 = Polygon(MoveBox9, MoveBox9 + (wid / 4, 0), MoveBox9 + (wid / 4, hei), MoveBox9 + (0, hei))
box5InMove: ¬Defined[IndexOf[MoveBox5, Positions]]
box6InMove: ¬Defined[IndexOf[MoveBox6, Positions]]
box7InMove: ¬Defined[IndexOf[MoveBox7, Positions]]
box8InMove: ¬Defined[IndexOf[MoveBox8, Positions]]
box9InMove: ¬Defined[IndexOf[MoveBox9, Positions]]
text5 = Text(labelsPoints(1), MoveBox5 + (wid / 4, hei) / 2, true, true, 0, 0)
text6 = Text(labelsPoints(2), MoveBox6 + (wid / 4, hei) / 2, true, true, 0, 0)
text7 = Text(labelsPoints(3), MoveBox7 + (wid / 4, hei) / 2, true, true, 0, 0)
text8 = Text(labelsPoints(4), MoveBox8 + (wid / 4, hei) / 2, true, true, 0, 0)
text9 = Text(labelsPoints(5), MoveBox9 + (wid / 4, hei) / 2, true, true, 0, 0)
box11InMove: ¬Defined[IndexOf[MoveBox11, Join[{Positions, TargetPointsUp}]]]
box10InMove: ¬Defined[IndexOf[MoveBox10, Join[{Positions, TargetPointsUp}]]]
box12InMove: ¬Defined[IndexOf[MoveBox12, Join[{Positions, TargetPointsUp}]]]
box1InReg: true ∈ Sequence[IsInRegion[Vertex[box1, ii], droparea], ii, 1, 4]
box2InReg: true ∈ Sequence[IsInRegion[Vertex[box2, ii], droparea], ii, 1, 4]
box3InReg: true ∈ Sequence[IsInRegion[Vertex[box3, ii], droparea], ii, 1, 4]
box4InReg: true ∈ Sequence[IsInRegion[Vertex[box4, ii], droparea], ii, 1, 4]
box5InReg: true ∈ Sequence[IsInRegion[Vertex[box5, ii], droparea], ii, 1, 4]
box6InReg: true ∈ Sequence[IsInRegion[Vertex[box6, ii], droparea], ii, 1, 4]
box7InReg: true ∈ Sequence[IsInRegion[Vertex[box7, ii], droparea], ii, 1, 4]
box8InReg: true ∈ Sequence[IsInRegion[Vertex[box8, ii], droparea], ii, 1, 4]
box9InReg: true ∈ Sequence[IsInRegion[Vertex[box9, ii], droparea], ii, 1, 4]
BoxInMovement = IndexOf(true, {box1InMove, box2InMove, box3InMove, box4InMove, box5InMove, box6InMove, box7InMove, box8InMove, box9InMove, box10InMove, box11InMove, box12InMove})
Ocuppies = Zip(If[kk ≤ 4, 4, If[kk ≤ 9, 1, 0]], kk, InDropArea)
PlaceOfEach = Sequence(1 + Sum[Ocuppies, ii - 1], ii, 1, Length[InDropArea])
MoveBox100 = (9.4, 4.11)
organizeOutside = Zip((((("SetValue(MoveBox" * ii) * ",Positions(") * ii) * "))"), ii, Sequence[9] \ InDropArea)
organizeInside = Zip((((("SetValue(MoveBox" * ii) * ",TargetPointsDown(") * kk) * "))"), ii, InDropArea, kk, PlaceOfEach)
text11 = Text("\longrightarrow", MoveBox11 + ((0.6 * wid), (1.2 * hei / 2)) / 2, true, true, 0, 0)
text12 = Text("\longleftrightarrow", MoveBox12 + ((0.6 * wid), hei / 2) / 2, true, true, 0, 0)
text10 = Text("−", MoveBox10 + ((0.55 * wid), hei / 2) / 2, true, true, 0, 0)
InDropAreaOrdered: {box1InReg, box2InReg, box3InReg, box4InReg, box5InReg, box6InReg, box7InReg, box8InReg, box9InReg}
ResetPositions = Sequence((((("SetValue(MoveBox" * ii) * ",Positions(") * ii) * "))"), ii, 1, 12)
P1 = Element(PointsAll, randomNum2 + numP1 - 1)
P2 = Element(PointsAll, randomNum2 + numP2 - 1)
distances10 = Zip(Distance[MoveBox10, PP], PP, TargetPointsUp)
ClosestPoint10 = Element(TargetPointsUp, IndexOf[Min[distances10], distances10])
distances11 = Zip(Distance[MoveBox11, PP], PP, TargetPointsUp)
distances12 = Zip(Distance[MoveBox12, PP], PP, TargetPointsUp)
ClosestPoint11 = Element(TargetPointsUp, IndexOf[Min[distances11], distances11])
ClosestPoint12 = Element(TargetPointsUp, IndexOf[Min[distances12], distances12])
Landing10 = Polygon({ClosestPoint10, ClosestPoint10 + (wid / 2, 0), ClosestPoint10 + (wid / 2, hei / 2), ClosestPoint10 + (0, hei / 2)})
Landing11 = Polygon({ClosestPoint11, ClosestPoint11 + (wid / 2, 0), ClosestPoint11 + (wid / 2, hei / 2), ClosestPoint11 + (0, hei / 2)})
Landing12 = Polygon({ClosestPoint12, ClosestPoint12 + (wid / 2, 0), ClosestPoint12 + (wid / 2, hei / 2), ClosestPoint12 + (0, hei / 2)})
PlaceOfEachUp: {If[box10InMove ∧ box10InReg, ClosestPoint10, Positions(10)], If[box11InMove ∧ box11InReg, ClosestPoint11, Positions(11)], If[box12InMove ∧ box12InReg, ClosestPoint12, Positions(12)]}
EnoughSpace = If(BoxInMovement ≤ 4, 9 - Sum[Ocuppies] ≥ 4, 9 - Sum[Ocuppies] ≥ 1)
activeDropArea: BoxInMovement ≤ 9 ∧ Element[InDropAreaOrdered, BoxInMovement] ∧ EnoughSpace
MoveGL = (8.5065, 1.2285)
hguideline: y = y(MoveGL)
vguideline: x = x(MoveGL)
hguideline' = Translate(hguideline, Vector[(Vector[Corner[3], Corner[2]] / 500 * 16)])
SinglePoint2: PointsToShow(numP2)
endpointArrow = Vector(SinglePoint + (0, If[y(SinglePoint) ≟ 0, 1, -1]), SinglePoint - (0, (0.1 * If[y(SinglePoint) ≟ 0, -1, 1])))
secondPointArrow = Vector(SinglePoint2 + (0, If[y(SinglePoint2) ≟ 0, 1, -1]), SinglePoint2 - (0, (0.1 * If[y(SinglePoint2) ≟ 0, -1, 1])))
NoEnds: Sequence[Vertex[If[randomNum1 ≟ 4, lineInWindow, rayInWindow], ii], ii, 1, 2] \ {SinglePoint, SinglePoint2}
arrowsNoEnd = Zip(Vector[PP + (0, If[y(PP) ≥ 4, -0.75, 0.75]), PP + (0, (0.1 * If[y(PP) ≥ 4, -1, 1]))], PP, NoEnds)
solutionAnim = 0 (slider from 0 to Min[randomNum1, 3], step 0.05)
speed = If(randomNum1 ≟ 2, 2, 1)
PointsInInputCurrent: KeepIf[5 ≤ x ≤ 9, inputCurrent] - 4
PointHint = Element(PointsToShow, PointsInInputCurrent(1))
PointHint2 = Element(PointsToShow, PointsInInputCurrent(2))
hintSegment = Segment(PointHint, PointHint2)
hintRay = Ray(PointHint, PointHint2)
hintLine = Line(PointHint, PointHint2)
hintLineInWindow_{1} = IntersectPath(hintLine, q1)
hintRayInWindow_{1} = IntersectPath(hintRay, q1)
expectedOrdered = Zip(Sort[ll], ll, expected)
u = If(box10InMove ∨ box11InMove, box12InMove)
v = If(box10InMove ∨ box11InMove, box12InMove)
w = If(box10InMove ∨ box11InMove, box12InMove)
o_1 = If(box10InMove ∨ box11InMove, box12InMove)
isTypicalError: (IsLine ∨ IsPoint ∨ IsRay ∨ IsSegment) ∧ (¬correct)
hintObject = false
NoEndsLabPos = Zip(PP + (1.5 * (0, If[y(PP) ≥ 4, -0.75, 0.75])), PP, NoEnds)
labelsPointsToShow = KeepIf(IndexOf[TT, labelsPoints] ≠ numP1 ∧ If[randomNum1 ≠ 1, IndexOf[TT, labelsPoints] ≠ numP2, true], TT, labelsPoints)
labelPoint2 = Element(labelsPoints, numP2)
pulsingRay = expandSegment(P1, Vertex[rayInWindow, 2], (7 * pulsing), Corner[1], Corner[3], Corner[5])
pulsingSegment = expandSegment(P1, P2, (7 * pulsing), Corner[1], Corner[3], Corner[5])
pulsingLine = expandSegment(Vertex[lineInWindow, 1], Vertex[lineInWindow, 2], (7 * pulsing), Corner[1], Corner[3], Corner[5])
wait = 1 (slider from 0 to 1)
pulsingObject = circlePixels(P1, 7 + (7 * pulsing), Corner[1], Corner[3], Corner[5])
vguideline' = Translate(vguideline, Vector[(Vector[Corner[1], Corner[2]] / 800 * 428)])
text14 = Text("\textsf{No end}", NoEndsLabPos(2) + (If[x(NoEndsLabPos(2)) ≤ 0, 0.6, x(NoEndsLabPos(2)) ≥ 8, -0.6, 0], 0), true, true, 0, 0)
labelsNoEnd = Zip(Text["\textsf{Infinito}", PP + (If[x(PP) ≤ 0, 0.6, x(PP) ≥ 8, -0.6, 0], 0), true, true, 0, 0], PP, NoEndsLabPos)
labelBtnValidate: "\text{CHEQUEAR (" + (LaTeX[3 - tries]) + ")}"
textFeedback: "" + (LaTeX[If[correct, "$\text{✓ Correcto}$", "$\text{✕ " + (If[tries < 3, "Reinténtalo", "Quizás la próxima vez"]) + "}$"]]) + ""
textCountCorrect: "\text{Correctos: " + (LaTeX[countCorrect]) + " }"
textHint: "\text{\textcolor{" + (LaTeX[colorOrange]) + "}\bold{Pista   }\\" + (LaTeX[If[showhinttypicalerror, helpTextHintTypicalError]]) + "" + (LaTeX[If[showhint ∧ showhinttypicalerror, ""]]) + "" + (LaTeX[If[showhint ∧ (¬showhinttypicalerror), helpTextHint]]) + "}"
textSolution: "\textsf{\bold{Posible solución}}\\
\textsf{" + (LaTeX[Element[{"Punto", "Segmento", "Semirrecta", "Recta"}, randomNum1]]) + " }" + (LaTeX[Element[{"{", "\overline{", "\overrightarrow{", "\overleftrightarrow{"}, randomNum1]]) + "" + (LaTeX[Element[{"A", "B", "C", "D", "E"}, IndexOf[PointsToShow(numP1), PointsToShowF]]]) + "" + (LaTeX[If[randomNum1 ≟ 1, "", Element[{"A", "B", "C", "D", "E"}, IndexOf[PointsToShow(numP2), PointsToShowF]]]]) + "}."
labelEndpoint1 = Text(If[randomNum1 ≟ 4, "\textsf{Point on line}", randomNum1 ≟ 1, "\textsf{Punto simple}", "\textsf{Extremo}"], SinglePoint - (If[x(SinglePoint) ≟ 8, 0.7, 0], If[y(SinglePoint) ≟ 0, -1, 1]), true, true, If[x(SinglePoint) ≟ 0, 1, 0], If[y(SinglePoint) ≟ 0, 1, -1])
labelSecondPoint = Text(If[randomNum1 ≟ 4, "\textsf{Punto en la recta}", randomNum1 ≟ 3, "\textsf{Punto en la semirrecta}", "\textsf{Extremo}"], SinglePoint2 - (If[x(SinglePoint2) ≟ 8, 0.7, 0], If[y(SinglePoint2) ≟ 0, -1, 1]), true, true, If[x(SinglePoint2) ≟ 0, 1, 0], If[y(SinglePoint2) ≟ 0, 1, -1])
text13 = Text("\textsf{Infinito}", NoEndsLabPos(1) + (If[x(NoEndsLabPos(1)) ≤ 0, 0.6, x(NoEndsLabPos(1)) ≥ 8, -0.6, 0], 0), true, true, 0, 0)
organizeUp = If(box10InMove ∨ box11InMove ∨ box12InMove, Zip[(((("SetValue(MoveBox" * (9 + ii)) * ",PlaceOfEachUp(") * ii) * "))"), ii, Append[Sequence[3] \ {BoxInMovement - 9}, BoxInMovement - 9]], {})
labelBtnAlternate = Text(If[¬hintObject, "$\textsf{MOSTRAR MI OBJETO}$", "$\textsf{MOSTRAR EL OBJETO DADO}$"], (0, 0), true, true)

Tool: PixelsToPoint
PixelsToPoint(Corner1,Corner3,Corner5,PixelCoords)
Input: Corner1, Corner3, Corner5, InputPixels
Output: OutputPoint

InputPixels: (100, 200)
xRight: x(Corner3)
xLeft: x(Corner1)
yTop: y(Corner3)
yBottom: y(Corner1)
yCoord: yTop - (y(InputPixels) / y(Corner5) * (yTop - yBottom))
xCoord: (x(InputPixels) / x(Corner5) * (xRight - xLeft)) + xLeft
OutputPoint: (xCoord, yCoord)

Tool: expandSegment
expandSegment(A,B,pixelGap,Corner1,Corner3,Corner5)
Input: A, B, pixelGap, Corner1, Corner3, Corner5
Output: newPoly

distanceX: (pixelGap / x(Corner5) * (x(Corner3) - x(Corner1)))
distanceY: (pixelGap / y(Corner5) * (y(Corner3) - y(Corner1)))
pointGap: distanceX
xyScale: distanceY / distanceX
A: (0, 0)
vecAB: B - A
pVec: (20 * UnitVector[(((-y(vecAB))) / xyScale, (x(vecAB) * xyScale))])
pVecAngle = Angle(xAxis, Line[(0, 0), pVec])
realAngle = If(pVecAngle ≟ pi / 2 ∨ pVecAngle ≟ (3 * pi / 2), pVecAngle, atand(tan(pVecAngle) / xyScale))
curveFunction = CurveCartesian((pointGap * cos(u)), ((pointGap * xyScale) * sin(u)), u, 0, (2 * pi))
K: curveFunction(realAngle)
vSpace = Vector(K)
allPoints: {A + vSpace, A - vSpace, B - vSpace, B + vSpace}
newPoly = Polygon(allPoints)

Tool: onboardingTextOffset
onboardingTextOffset(textCorner1,textCorner3,case,corner1,corner3,corner5)
Input: CornerText1, CornerText3, case, Corner1, Corner3, Corner5
Output: TextOffset

xPixels: ((x(CornerText3) - x(CornerText1)) * x(Corner5) / (x(Corner3) - x(Corner1)))
yPixels: ((y(CornerText3) - y(CornerText1)) * y(Corner5) / (y(Corner3) - y(Corner1)))
xOffset = Element({27, (-xPixels) + 2, 16 - xPixels / 2, 16 - xPixels / 2}, case)
yOffset = Element({-23, -23, yPixels - 27, -49}, case)
TextOffset: (xOffset, yOffset)

Tool: circlePixels
circlePixels(A,pixelRadius,Corner1,Corner3,Corner5
Input: A, pixelRadius, Corner1, Corner3, Corner5
Output: newCircle

pointRadius: (pixelRadius / x(Corner5) * (x(Corner3) - x(Corner1)))
newCircle = Circle(A, pointRadius)