How many coordinates are unreachable?

153 Views Asked by At

I wanted to know, if a man was to go from $(0,0)$ to $(46,46)$ moving only straight and up with the following constraints:-

  1. If he walks right, he will walk atleast $4$ consecutive coordinates.

  2. If he moves up, he will walk atleast $12 $ consecutive coordinates.

How many coordinates are unreachable by him in this $46 \times 46$ grid? (Assumption:A coordinate is reachable by the man if he runs through the coordinate.)

Any help is appreciated. Thanks.

2

There are 2 best solutions below

7
On BEST ANSWER

The reachable points are those that lie on the $1,4,8,12,\dots,40,44$ numbered columns and $1,12,24,36$ numbered rows(numbering being done from bottom to top and from left to right.)

3
On

All the coordinates but the ones contained within the rectangle with vertices $\,(0,0)\,,\,(4,0)\,,\,(0,12)\,,\,(4,12)\,$ (not including the perimeter) are reachable with the addition of that "at least" thing and understanding that "reachable" means passing through, as you wrote, not stopping there...

For example ,$\,(3,9)\,$ is unreachable, but for $\,a\ge 4\;,\;b\ge 12\;,\;\;(a,b)\;$ is reachable: just walk $\,a\;$ steps rightwards and then $\,b\,$ steps upwards...

In fact, we could say any coordinate of the form $\,(a,b)\;,\;\;a\ge 4\;\;or\;\;b\ge 12\;$ , is reachable...