Wish for Well

Algebra Level 5

A wishing well is located at the point (11, 11) in the xy-plane. Sanket randomly selects an integer y from the set {0, 1, . . . , 10}. Then he randomly selects, with replacement, two integers a, b from the set {1, 2, . . . , 10}. The probability the line through (0, y) and (a, b) passes through the well can be expressed as m/ n , where m and n are relatively prime positive integers. Compute m + n.


The answer is 111.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

1 solution

Bill Bell
Oct 8, 2015

Computer scripts have a way of making situations very clear.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
from itertools import product
from sympy import Point,Line
from fractions import Fraction

wishingWell=Point(11,11)

m=0
n=0
for a,b,y in product(range(1,11),range(1,11),range(0,11)):
    line=Line(Point(a,b),Point(0,y))
    m+=1 if line.distance(wishingWell)==0 else 0
    n+=1
print m,n,Fraction(m,n)

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...