• Wandering Robot

    From David Entwistle@qnivq.ragjvfgyr@ogvagrearg.pbz to rec.puzzles on Mon Sep 7 04:02:19 2026
    From Newsgroup: rec.puzzles

    A robot sits in the top-left corner square of a 4 x 4 grid of squares. It
    can only move to the right or down, and it must reach the bottom-right
    corner. How many different routes are possible?

    https://ibb.co/N6pRVYgT

    Note: I found the answer, but don't immediately see how that relates to a general solution involving factorials. A good explanation of that
    relationship would be welcome.

    Thanks,
    --
    David Entwistle
    --- Synchronet 3.22a-Linux NewsLink 1.2
  • From msb@msb@vex.net (Mark Brader) to rec.puzzles on Mon Sep 7 07:22:12 2026
    From Newsgroup: rec.puzzles

    David Entwistle:
    A robot sits in the top-left corner square of a 4 x 4 grid of squares. It can only move to the right or down, and it must reach the bottom-right corner. How many different routes are possible?

    Assuming that it is constrained to move 1 square at a time, then it must
    take 3 steps down and 3 to the right, and these can be in any order.
    The number of permutations of DDDRRR is 6!/(3!3!) = 20, giving that many possible routes.

    If it is allowed to step 2 or 3 squares at a time, the routes are the
    same (for example, DD replaces D and D), ao there are still 20 routes.

    If it is allowed to travel in increments of any length, then the number
    of possible routes is infinite.
    --
    Mark Brader, Toronto | Thus, "plain english" is the same as
    msb@vex.net | "near-field spin". --Carl Ginnow

    My text in this article is in the public domain.
    --- Synchronet 3.22a-Linux NewsLink 1.2
  • From James Dow Allen@user4353@newsgrouper.org.invalid to rec.puzzles on Mon Sep 7 17:16:20 2026
    From Newsgroup: rec.puzzles


    msb@vex.net (Mark Brader) posted:
    David Entwistle:
    A robot sits in the top-left corner square of a 4 x 4 grid of squares. It can only move to the right or down, and it must reach the bottom-right corner. How many different routes are possible?

    Assuming that it is constrained to move 1 square at a time, then it must
    take 3 steps down and 3 to the right, and these can be in any order.

    I assume a "4 x 4 grid of SQUARES" has FOUR squares across and down;
    i.e. is defined by a 5 x 5 grid of points. The answer is thus C(8,4) = 70,
    the same as Mark derived but with different numbers.

    The way David phrases his question, he may be looking for a way to short-circuit the counting function C(8,4) and go from the problem
    statement directly to factorials. I don't know how.

    Cheers,
    James
    --- Synchronet 3.22a-Linux NewsLink 1.2
  • From msb@msb@vex.net (Mark Brader) to rec.puzzles on Mon Sep 7 19:52:29 2026
    From Newsgroup: rec.puzzles

    David Entwistle:
    A robot sits in the top-left corner square of a 4 x 4 grid of squares. It >>> can only move to the right or down, and it must reach the bottom-right
    corner. How many different routes are possible?

    Mark Brader:
    Assuming that it is constrained to move 1 square at a time, then it must
    take 3 steps down and 3 to the right, and these can be in any order.

    James Dow Allen:
    I assume a "4 x 4 grid of SQUARES" has FOUR squares across and down;
    i.e. is defined by a 5 x 5 grid of points.

    Agreed, but if the robot sites *in* a certain square, I assume we are
    to assume that it sits on the center of the square, and if it moves
    in steps from one square to another, the centers are where it goes.

    The way David phrases his question, he may be looking for a way to short-circuit the counting function C(8,4) and go from the problem
    statement directly to factorials. I don't know how.

    See my answer.
    --
    Mark Brader, Toronto | "You know you've made it when you have
    msb@vex.net | a disease named after you." --Andrew Niccol

    My text in this article is in the public domain.
    --- Synchronet 3.22a-Linux NewsLink 1.2
  • From David Entwistle@qnivq.ragjvfgyr@ogvagrearg.pbz to rec.puzzles on Tue Sep 8 08:46:53 2026
    From Newsgroup: rec.puzzles

    On Mon, 7 Sep 2026 04:02:19 -0000 (UTC), David Entwistle wrote:

    Note: I found the answer, but don't immediately see how that relates to
    a general solution involving factorials. A good explanation of that relationship would be welcome.

    My thoughts ...
    y thoughts ...
    thoughts ...
    thoughts ...
    houghts ...
    oughts ...
    ughts ...
    ghts ...
    hts ...
    ts ...
    s ...
    ...
    ...
    ..
    .

    Thanks for the replies. My solution is sketched out here:

    https://ibb.co/wrzSWXBw

    The problem is easy to break down in to smaller parts. There is only one
    way to reach any of the squares in the top row; and only one way to reach
    any of the squares in the left column. There are two ways to reach cell
    number 6, and three ways to reach cell number 7. It quickly becomes clear
    that the number of possible routes, to any particular cell, is the sum of
    the routes to the cells that can access that cell (that is the sum of the routes to the cell above and to the left). Working thought that, the
    answer, how many routes between top-left and bottom-right is 20, or 70 if
    you have the additional column and row.

    The problem was posed by an AI LLM, which provided the solution provided
    by Mark, based on factorials.

    For the smaller grid, which requires six moves to reach the diagonally opposing corner, I can see intuitively that are 6! ways of ordering those moves, if each is considered unique. I haven't yet seen, intuitively, how having two distinct groups of similar moves, R and D, decreases the 6! =
    720 to 20, but it clearly does.

    The sequence of moves for different sized grids; 1, 2, 6, 20, 70,
    252 ...is described in OEIS series A000984.

    https://oeis.org/A000984

    The above provides lots of interesting information about the Catalan
    numbers and their relationship to Pascal's triangle. I'll read up on the binomial theorem, which I recall vaguely from school.

    Best wishes,
    --
    David Entwistle
    --- Synchronet 3.22a-Linux NewsLink 1.2
  • From ram@ram@zedat.fu-berlin.de (Stefan Ram) to rec.puzzles on Tue Sep 8 23:21:26 2026
    From Newsgroup: rec.puzzles

    David Entwistle <qnivq.ragjvfgyr@ogvagrearg.pbz> wrote or quoted:
    A robot sits in the top-left corner square of a 4 x 4 grid of squares. It >can only move to the right or down, and it must reach the bottom-right >corner. How many different routes are possible?

    SPOILER WARNING This is an attempt to write an answer.

    The robot has to move three times right and three times down.
    We can only vary the order of those six moves.

    For six different object, there are 6! individual orders, but
    now we identify three objects twice, so the number should be
    divided twice by 3!. This would give 6!/3!/3! = 720/6/6 = 120/6
    = 20.

    Now, a small Python program to test this!

    source code

    import itertools
    seen = set()
    n = 0
    for p in itertools.permutations( [ 1, 1, 1, 2, 2, 2 ]):
    if not p in seen:
    seen.add( p )
    n += 1
    print(n)

    output

    20

    Disclaimer I made an error first writing "6!/(2*3!)" which
    is 60, but when I then saw that my Python script printed "20",
    I corrected this. But otherwise I wrote this post without
    looking up anything, not even for writing the Python script.


    --- Synchronet 3.22a-Linux NewsLink 1.2
  • From David Entwistle@qnivq.ragjvfgyr@ogvagrearg.pbz to rec.puzzles on Fri Sep 11 08:17:45 2026
    From Newsgroup: rec.puzzles

    On Tue, 8 Sep 2026 08:46:53 -0000 (UTC), David Entwistle wrote:

    I'll read up on the binomial theorem, which I recall vaguely from
    school.

    Chapter 3 'What Comes Next?' of 'The Book of Numbers' covers related
    problems, covers quite some ground, but does provide the background.
    --
    David Entwistle
    --- Synchronet 3.22a-Linux NewsLink 1.2