CEMC Banner

2019 Euclid Contest
Solutions

Wednesday, April 3, 2019
(in North America and South America)

Thursday, April 4, 2019
(outside of North American and South America)

©2019 University of Waterloo


    1. Solution 1

      Since 34 of a jar has a volume of 300 mL, then 14 of a jar has a volume of (300 mL)÷3 or 100 mL.

      Solution 2

      Since 34 of a jar has a volume of 300 mL, then the volume of the entire jar is 43(300 mL) or 400 mL.

      In this case, the volume of 14 of the jar is (400 mL)÷4=100 mL.

    2. We note that since 24a>3>0, then a is positive.

      Since 3<24a and a>0, then a<243=8.

      Since 24a<4 and a>0, then a>244=6.

      Since 6<a<8 and a is an integer, then a=7.

      Note that it is indeed true that 3<247<4.

    3. Since x and x2 appear in the denominators of the equation, then x0.

      Multiplying by x2 and manipulating, we obtain successively 1x21x=21x=2x20=2x2+x10=(2x1)(x+1) and so x=12 or x=1.

      Checking in the original equation we obtain, 1(1/2)211/2=11/411/2=42=2 and 1(1)211=11+1=2 and so the solutions to the equation are x=12 and x=1.

    1. Since the radius of the large circle is 2, its area is π22=4π.

      Since the radius of each small circle is 1, the area of each small circle is π12=π.

      Since the two small circles are tangent to each other and to the large circle, then their areas do not overlap and are contained entirely within the large circle.

      Since the shaded region consists of the part of the large circle that is outside the two small circles, then the shaded area is 4πππ=2π.

    2. Mo starts at 10:00 a.m. and finishes at 11:00 a.m. and so runs for 1 hour.

      Mo runs at 6 km/h, and so runs 6 km in 1 hour.

      Thus, Kari also runs 6 km.

      Since Kari runs at 8 km/h, then Kari runs for 6 km8 km/h=34 h which is 45 minutes.

      Since Kari finishes at 11:00 a.m., then Kari started at 10:15 a.m.

    3. The equation x+3y=7 can be rearranged to 3y=x+7 and y=13x+73.

      Therefore, the line with this equation has slope 13.

      Since the two lines are parallel and the line with equation y=mx+b has slope m, then m=13.

      Thus, the equation of the second line can be re-written as y=13x+b.

      Since (9,2) lies on this line, then 2=139+b and so 2=3+b, which gives b=5.

    1. Michelle’s list consists of 8 numbers and so its average is 5+10+15+16+24+28+33+378=1688=21 Daphne’s list thus consists of 7 numbers (one fewer than in Michelle’s list) with an average of 20 (1 less than that of Michelle).

      The sum of 7 numbers whose average is 20 is 720=140.

      Since the sum of Michelle’s numbers was 168, then Daphne removed the number equal to 168140 which is 28.

    2. Since 16=24 and 32=25, then the given equation is equivalent to the following equations (24)15/x=(25)4/3260/x=220/3 This means that 60x=203=609 and so x=9.

    3. Using exponent laws, the following equations are equivalent: 22022+2a22019=72220222019+2a2019=7223+2a2019=728+2a2019=722a2019=642a2019=26 which means that a2019=6 and so a=2025.

    1. Solution 1

      Since CDB is right-angled at B, then DCB=90CDB=30.

      This means that CDB is a 30-60-90 triangle.

      Using the ratios of side lengths in a 30-60-90 triangle, CD:DB=2:1.

      Since DB=10, then CD=20.

      Since CDB=60, then ADC=180CDB=120.

      Since the angles in ADC add to 180, then DAC=180ADCACD=30.

      This means that ADC is isosceles with AD=CD.

      Therefore, AD=CD=20.

      Solution 2

      Since CDB is right-angled at B, then DCB=90CDB=30.

      Since ACB is right-angled at B, then CAB=90ACB=90(30+30)=30.

      This means that each of CDB and ACB is a 30-60-90 triangle.

      Using the ratios of side lengths in a 30-60-90 triangle, CB:DB=3:1.

      Since DB=10, then CB=103.

      Similarly, AB:CB=3:1.

      Since CB=103, then AB=3103=30.

      Finally, this means that AD=ABDB=3010=20.

    2. Since the points A(d,d) and B(d+12,2d6) lie on the same circle centered at the origin, O, then OA=OB.

      Since distances are always non-negative, the following equations are equivalent: (d0)2+(d0)2=((d+12)0)2+((2d6)0)2d2+(d)2=(d+12)2+(2d6)2d2+d2=d224d+144+4d224d+362d2=5d248d+1800=3d248d+1800=d216d+600=(d10)(d6) and so d=10 or d=6.

      We can check that the points A(10,10) and B(2,14) are both of distance 200 from the origin and the points A(6,6) and B(6,6) are both of distance 72 from the origin.

    1. First, we note that 50=52.

      Next, we note that 2+42=52 and 22+32=52.

      From the first of these, we obtain 2+32=50.

      From the second of these, we obtain 8+18=50.

      Thus, (a,b)=(2,32) and (a,b)=(8,18) are solutions to the original equation.

      (We are not asked to justify why these are the only two solutions.)

    2. From the second equation, we note that d0.

      Rearranging this second equation, we obtain c=kd.

      Substituting into the first equation, we obtain kd+d=2000 or (k+1)d=2000.

      Since k0, note that k+11.

      This means that if (c,d) is a solution, then k+1 is a divisor of 2000.

      Also, if k+1 is a divisor of 2000, then the equation (k+1)d=2000 gives us an integer value of d (which is non-zero) from which we can find an integer value of c using the first equation.

      Therefore, the values of k that we want to count correspond to the positive divisors of 2000.

      Since 2000=101020=2453, then 2000 has (4+1)(3+1)=20 positive divisors.

      This comes from the fact that if p and q are distinct prime numbers then the positive integer paqb has (a+1)(b+1) positive divisors.

      We could list these divisors as 1,2,4,5,8,10,16,20,25,40,50,80,100,125,200,250,400,500,1000,2000 if we did not know the earlier formula.

      Since 2000 has 20 positive divisors, then there are 20 values of k for which the system of equations has at least one integer solution.

      For example, if k+1=8, then k=7. This gives the system c+d=2000 and cd=7 which has solution (c,d)=(1750,250).

    1. Solution 1

      The angles in a polygon with n sides have a sum of (n2)180.

      This means that the angles in a pentagon have a sum of 3180 or 540, which means that each interior angle in a regular pentagon equals 15540 or 108.

      Also, each interior angle in a regular polygon with n sides equals n2n180. (This is the general version of the statement in the previous sentence.)

      Consider the portion of the regular polygon with n sides that lies outside the pentagon and join the points from which the angles that measure a and b emanate to form a hexagon.

      The newly formed hexagon is described as follows.

      This polygon has 6 sides, and so the sum of its 6 angles is 4180.

      Four of its angles are the original angles from the n-sided polygon, so each equals n2n180.

      The remaining two angles have measures a+c and b+d.

      We are told that a+b=88.

      Also, the angles that measure c and d are two angles in a triangle whose third angle is 108.

      Thus, c+d=180108=72.

      Therefore, 4n2n180+88+72=4180160=(44(n2)n)180160=4n(4n8)n180160180=8n89=8n and so the value of n is 9.

      Solution 2

      The angles in a polygon with n sides have a sum of (n2)180.

      This means that the angles in a pentagon have a sum of 3180 or 540, which means that each interior angle in a regular pentagon equals 15540 or 108.

      Also, each interior angle in a regular polygon with n sides equals n2n180. (This is the general version of the statement in the previous sentence.)

      Consider the portion of the regular polygon with n sides that lies outside the pentagon.

      The outside portion of the regular pentagon vaguely resembles the letter 'C'. The five visible sides of the polygon form the outside of the 'C'. On the inside of the arc lie the two sides of the pentagon.

      This polygon has 7 sides, and so the sum of its 7 angles is 5180.

      Four of its angles are the original angles from the n-sided polygon, so each equals n2n180.

      Two of its angles are the angles equal to a and b, whose sum is 88.

      Its seventh angle is the reflex angle corresponding to the pentagon’s angle of 108, which equals 360108 or 252.

      Therefore, 4n2n180+88+252=5180340=(54(n2)n)180340=5n(4n8)n180340180=n+8n179=n+8n17n=9(n+8)17n=9n+728n=72 and so the value of n is 9.

    2. Since the lengths of AD, AB and BC form a geometric sequence, we suppose that these lengths are a, ar and ar2, respectively, for some real numbers a>0 and r>0.

      Since the angles at A and B are both right angles, we assign coordinates to the diagram, putting B at the origin (0,0), C on the positive x-axis at (ar2,0), A on the positive y-axis at (0,ar), and D at (a,ar).

      Recall that AD is parallel to BC.

      Therefore, the slope of the line segment joining B(0,0) and D(a,ar) is ar0a0=r.

      Also, the slope of the line segment joining A(0,ar) and C(ar2,0) is ar00ar2=1r.

      Since the product of the slopes of these two line segments is 1, then the segments are perpendicular, as required.

    1. Using logarithm and exponent laws, we obtain the following equivalent equations: 2log2(x1)=1log2(x+2)2log2(x1)+log2(x+2)=1log2((x1)2)+log2(x+2)=1log2((x1)2(x+2))=1(x1)2(x+2)=21(x22x+1)(x+2)=2x33x+2=2x33x=0x(x23)=0 and so x=0 or x=3 or x=3.

      Note that if x=0, then x1=1<0 and so log2(x1) is not defined. Thus, x0.

      Note that if x=3, then x1=31<0 and so log2(x1) is not defined. Thus, x3.

      If x=3, we can verify that both logarithms in the original equation are defined and that the original equation is true. We could convince ourselves of this with a calculator or we could algebraically verify that raising 2 to the power of both sides gives the same number, so the expressions must actually be equal.

      Therefore, x=3 is the only solution.

    2. Let a=f(f(x)).

      Thus, the equation f(f(f(x)))=3 is equivalent to f(a)=3.

      Since f(a)=a22a, then we obtain the equation a22a=3 which gives a22a3=0 and (a3)(a+1)=0.

      Thus, a=3 or a=1 which means that f(f(x))=3 or f(f(x))=1.

      Let b=f(x).

      Thus, the equations f(f(x))=3 and f(f(x))=1 become f(b)=3 and f(b)=1.

      If f(b)=3, then b=f(x)=3 or b=f(x)=1 using similar reasoning to above when f(a)=3.

      If f(b)=1, then b22b=1 and so b22b+1=0 or (b1)2=0 which means that b=f(x)=1.

      Thus, f(x)=3 or f(x)=1 or f(x)=1.

      If f(x)=3, then x=3 or x=1 as above.

      If f(x)=1, then x=1 as above.

      If f(x)=1, then x22x=1 and so x22x1=0.

      By the quadratic formula, x=(2)±(2)24(1)(1)2(1)=2±82=1±2 Therefore, the solutions to the equation f(f(f(x)))=3 are x=3,1,1,1+2,12.

    1. Consider a circle lying inside a quadrilateral ABCD.

      All four sides of the quadrilateral are tangent to the circle. P is the point of tangency on AB, Q is on BC, S is on CD, and T is on DA.

      Join point O to P, B, Q, C, S, D, T, and A.

      Since P, Q, S, and T are points of tangency, then the radii meet the sides of ABCD at right angles at these points.

      Since AO=3 and OT=1 and OTA=90, then by the Pythagorean Theorem, AT=AO2OT2=8=22.

      Since OTA is right-angled at T, then TAO+AOT=90.

      Since DOA=90, then AOT+DOT=90.

      Thus, TAO=DOT.

      This means that ATO is similar to OTD.

      Thus, DTOT=OTAT and so DT=OT2AT=122.

      Since DS and DT are tangents to the circle from the same point, then DS=DT=122.

    2. Since 0<x<π2, then 0<cosx<1 and 0<sinx<1.

      This means that 0<32cosx<32 and 0<32sinx<32. Since 3<π, then 0<32cosx<π2 and 0<32sinx<π2.

      If Y and Z are angles with 0<Y<π2 and 0<Z<π2, then cosY=sinZ exactly when Y+Z=π2. To see this, we could picture points R and S on the unit circle corresponding to the angles Y and Z; the x-coordinate of R is equal to the y-coordinate of S exactly when the angles Y and Z are complementary.

      Therefore, the following equations are equivalent: cos(32cosx)=sin(32sinx)32cosx+32sinx=π2cosx+sinx=π3(sinx+cosx)2=π29sin2x+2sinxcosx+sin2x=π292sinxcosx+(sin2x+cos2x)=π29sin2x+1=π29sin2x=π299 Therefore, the only possible value of sin2x is π299.

    1. By definition, f(2,5)=25+52+125=22+55+125=4+25+110=3010=3.

    2. By definition, f(a,a)=aa+aa+1a2=2+1a2.

      For 2+1a2 to be an integer, it must be the case that 1a2 is an integer.

      For 1a2 to be an integer and since a2 is an integer, a2 needs to be a divisor of 1.

      Since a2 is positive, then a2=1.

      Since a is a positive integer, then a=1.

      Thus, the only positive integer a for which f(a,a) is an integer is a=1.

    3. Suppose that a and b are positive integers for which f(a,b) is an integer.

      Assume that k=f(a,b) is not a multiple of 3.

      We will show that there must be a contradiction, which will lead to the conclusion that k must be a multiple of 3.

      By definition, k=f(a,b)=ab+ba+1ab.

      Multiplying by ab, we obtain kab=a2+b2+1, which we re-write as a2(kb)a+(b2+1)=0.

      We treat this as a quadratic equation in a with coefficients in terms of the variables b and k.

      Solving for a in terms of b and k using the quadratic formula, we obtain a=kb±(kb)24(1)(b2+1)2=kb±k2b24b242 Since a is an integer, then the discriminant k2b24b24 must be a perfect square.

      Re-writing the discriminant, we obtain k2b24b24=b2(k24)4=b2(k2)(k+2)4 Since k is not a multiple of 3, then it is either 1 more than a multiple of 3 or it is 2 more than a multiple of 3.

      If k is 1 more than a multiple of 3, then k+2 is a multiple of 3.

      If k is 2 more than a multiple of 3, then k2 is a multiple of 3.

      In either case, (k2)(k+2) is a multiple of 3, say (k2)(k+2)=3m for some integer m.

      This means that the discriminant can be re-written again as b2(3m)4=3(b2m2)+2 In other words, the discriminant is itself 2 more than a multiple of 3.

      However, every perfect square is either a multiple of 3 or one more than a multiple of 3:

      Suppose that r is an integer and consider r2.

      The integer r can be written as one of 3q, 3q+1, 3q+2, for some integer q.

      These three cases give (3q)2=9q2=3(3q2)(3q+1)2=9q2+6q+1=3(3q2+2q)+1(3q+2)2=9q2+12q+4=3(3q2+4q+1)+1 and so r2 is either a multiple of 3 or 1 more than a multiple of 3.

      We have determined that the discriminant is a perfect square and is 2 more than a multiple of 3. This is a contradiction.

      This means that our initial assumption must be incorrect, and so k=f(a,b) must be a multiple of 3.

    4. Solution 1

      We find additional pairs of positive integers (a,b) with f(a,b)=3.

      Suppose that f(a,b)=3.

      This is equivalent to the equations ab+ba+1ab=3 and a2+b23ab+1=0.

      Then f(b,3ba)3=b3ba+3bab+1b(3ba)3=b2+(3ba)2+13b(3ba)b(3ba)=b2+(3ba)(3ba)+13b(3ba)b(3ba)=b2a(3ba)+1b(3ba)=b2+a23ab+1b(3ba)=0 Therefore, if f(a,b)=3, then f(b,3ba)=3.

      The equation f(1,2)=3 gives f(2,3(2)1)=f(2,5)=3.

      The equation f(2,5)=3 gives f(5,3(5)2)=f(5,13)=3.

      The equation f(5,13)=3 gives f(13,3(13)5)=f(13,34)=3.

      The equation f(13,34)=3 gives f(34,3(34)13)=f(34,89)=3.

      The equation f(34,89)=3 gives f(89,3(89)34)=f(89,233)=3.

      Thus, the pairs (a,b)=(5,13),(13,34),(34,89),(89,233) satisfy the requirements.

      Solution 2

      From (a), we know that f(2,5)=3.

      Since the function f(a,b) is symmetric in a and b (that is, a and b can be switched without changing the value of the function), then f(5,2)=3.

      Consider the equation f(5,b)=3. We know that b=2 is a solution, but is there another solution?

      By definition, f(5,b)=5b+b5+15b.

      Thus, f(5,b)=3 gives the following equivalent equations: 5b+b5+15b=325+b2+1=15bb215b+26=0(b2)(b13)=0 and so b=2 or b=13. This means that f(5,13)=3 and so (a,b)=(5,13) has the property that f(a,b) is an integer.

      From f(5,13)=3, we get f(13,5)=3.

      As above, we consider the equation f(13,b)=3, for which b=5 is a solution.

      We obtain the equivalent equations 13b+b13+113b=3169+b2+1=39bb239b+170=0(b5)(b34)=0 and so b=5 or b=34. This means that f(13,34)=3 and so (a,b)=(13,34) has the property that f(a,b) is an integer.

      Continuing in a similar manner, we can also find that f(34,89) and f(89,233) are both integers.

      Thus, the pairs (a,b)=(5,13),(13,34),(34,89),(89,233) satisfy the requirements.

      Solution 3

      Note that f(5,13)=513+135+1513=52+132+165=19565=3f(13,34)=1334+3413+11334=132+342+1442=1326442=3f(34,89)=3489+8934+13489=342+892+13026=90783026=3f(89,233)=89233+23389+189233=892+2332+120737=6221120737=3 and so the pairs (a,b)=(5,13),(13,34),(34,89),(89,233) satisfy the requirements.

      Where do these pairs come from?

      We define the Fibonacci sequence F1,F2,F3,F4, by F1=F2=1 and Fn=Fn1+Fn2 when n3.

      Thus, the Fibonacci sequence begins 1,1,2,3,5,8,13,21,34,55,89,.

      The pairs (a,b) found above are of the form (F2k1,F2k+1) for integers k3.

      We note that f(F2k1,F2k+1)=F2k1F2k+1+F2k+1F2k1+1F2k1F2k+1=(F2k1)2+(F2k+1)2+1F2k1F2k+1=(F2k1)2+(F2k+F2k1)2+1F2k1(F2k+F2k1)=2(F2k1)2+2F2kF2k1+(F2k)2+1(F2k1)2+F2kF2k1=2(F2k1)2+2F2kF2k1(F2k1)2+F2kF2k1+(F2k)2+1(F2k1)2+F2kF2k1=2+(F2k)2+1F2k1F2k+1 This means that f(F2k1,F2k+1)=3 if and only if (F2k)2+1F2k1F2k+1=1, or equivalently if and only if (F2k)2+1=F2k1F2k+1, or (F2k)2F2k1F2k+1=1.

      We note that (F2)2F1F3=1212=1 and (F4)2F3F5=3225=1 so this is true when k=1 and k=2.

      Furthermore, we note that (F2k+2)2F2k+1F2k+3=(F2k+2)2F2k+1(F2k+2+F2k+1)=(F2k+2)2F2k+1F2k+2(F2k+1)2=F2k+2(F2k+2F2k+1)(F2k+1)2=F2k+2F2k(F2k+1)2=(F2k+1+F2k)F2k(F2k+1)2=(F2k)2+F2k+1F2k(F2k+1)2=(F2k)2+F2k+1(F2kF2k+1)=(F2k)2+F2k+1(F2k1)=(F2k)2F2k+1F2k1 which means that since (F4)2F3F5=1, then (F6)2F5F7=1, which means that (F8)2F7F9=1, and so on.

      Continuing in this way, (F2k)2F2k1F2k+1=1 for all positive integers k1, which in turn means that f(F2k1,F2k+1)=3, as required.

    1. On her first two turns, Brigitte either chooses two cards of the same colour or two cards of different colours. If she chooses two cards of different colours, then on her third turn, she must choose a card that matches one of the cards that she already has.

      Therefore, the game ends on or before Brigitte’s third turn.

      Thus, if Amir wins, he wins on his second turn or on his third turn. (He cannot win on his first turn.)

      For Amir to win on his second turn, the second card he chooses must match the first card that he chooses.

      On this second turn, there will be 5 cards in his hand, of which 1 matches the colour of the first card that he chose.

      Therefore, the probability that Amir wins on his second turn is 15.

      Note that there is no restriction on the first card that he chooses or the first card that Brigitte chooses.

      For Amir to win on his third turn, the following conditions must be true: (i) the colour of the second card that he chooses is different from the colour of the first card that he chooses, (ii) the colour of the second card that Brigitte chooses is different from the colour of the first card that she chooses, and (iii) the colour of the third card that Amir chooses matches the colour of one of the first two cards.

      The probability of (i) is 45, since he must choose any card other than the one that matches the first one.

      The probability of (ii) is 23, since Brigitte must choose either of the cards that does not match her first card.

      The probability of (iii) is 24, since Amir can choose either of the 2 cards that matches one of the first two cards that he chose.

      Again, the cards that Amir and Brigitte choose on their first turns do not matter.

      Thus, the probability that Amir wins on his third turn is 452324 which equals 415.

      Finally, the probabilty that Amir wins the game is thus 15+415 which equals 715.

    2. Suppose that, after flipping the first 13 coins, the probability that there is an even number of heads is p.

      Then the probability that there is an odd number of heads is 1p.

      When the 14th coin is flipped, the probability of heads is h14 and the probability of not heads is 1h14.

      After the 14th coin is flipped, there can be an even number of heads if the first 13 include an even number of heads and the 14th is not heads, or if the first 13 include an odd number of heads and the 14th is heads.

      The probability of this is p(1h14)+(1p)h14.

      Therefore, p(1h14)+(1p)h14=122p2ph14+2h142ph14=10=4ph142p2h14+10=2p(2h141)(2h141)0=(2p1)(2h141) Therefore, either h14=12 or p=12.

      If h14=12, we have proven the result.

      If h1412, then p=12.

      This would mean that the probability of getting an even number of heads when the first 13 coins are flipped is 12.

      We could repeat the argument above to conclude that either h13=12 or the probability of obtaining an even number of heads when the first 12 coins are flipped is 12.

      Continuing in this way, either one of h14,h13,,h3,h2 will equal 12, or the probability of obtaining an even number of heads when 1 coin is flipped is 12.

      This last statement is equivalent to saying that the probability of obtaining a head with the first coin is 12 (that is, h1=12).

      Therefore, at least one of h1,h2,,h13,h14 must equal 12.

    3. For the sum of the two digits printed to be 2, each digit must equal 1.

      Thus, S(2)=p1q1.

      For the sum of the two digits printed to be 12, each digit must equal 6.

      Thus, S(12)=p6q6.

      For the sum of the two digits printed to be 7, the digits must be 1 and 6, or 2 and 5, or 3 and 4, or 4 and 3, or 5 and 2, or 6 and 1.

      Thus, S(7)=p1q6+p2q5+p3q4+p4q3+p5q2+p6q1.

      Since S(2)=S(12), then p1q1=p6q6.

      Since S(2)>0 and S(12)>0, then p1,q1,p6,q6>0.

      If p1=p6, then we can divide both sides of p1q1=p6q6 by p1=p6 to obtain q1=q6.

      If q1=q6, then we can divide both sides of p1q1=p6q6 by q1=q6 to obtain p1=p6.

      Therefore, if we can show that either p1=p6 or q1=q6, our result will be true.

      Suppose that p1p6 and q1q6.

      Since S(2)=12S(7) and S(12)=12S(7), then S(7)12S(7)12S(7)=0S(7)S(2)S(12)=0p1q6+p2q5+p3q4+p4q3+p5q2+p6q1p1q1p6q6=0p1q6+p6q1p1q1p6q6+(p2q5+p3q4+p4q3+p5q2)=0(p1p6)(q6q1)+(p2q5+p3q4+p4q3+p5q2)=0p2q5+p3q4+p4q3+p5q2=(p1p6)(q6q1)p2q5+p3q4+p4q3+p5q2=(p1p6)(q1q6) Since p2,p3,p4,p5,q2,q3,q4,q50, then p2q5+p3q4+p4q3+p5q20.

      From this, (p1p6)(q1q6)0.

      Since p1p6, then either p1>p6 or p1<p6.

      If p1>p6, then p1p6>0 and so (p1p6)(q1q6)0 tells us that q1q6>0 which means q1>q6.

      But we know that p1q1=p6q6 and p1,q1,p6,q6>0 so we cannot have p1>p6 and q1>q6.

      If p1<p6, then p1p6<0 and so (p1p6)(q1q6)0 tells us that q1q6<0 which means q1<q6.

      But we know that p1q1=p6q6 and p1,q1,p6,q6>0 so we cannot have p1<p6 and q1<q6. This is a contradiction.

      Therefore, since we cannot have p1>p6 or p1<p6, it must be the case that p1=p6 which means that q1=q6, as required.