wu :: forums (http://www.ocf.berkeley.edu/~wwu/cgi-bin/yabb/YaBB.cgi)
riddles >> hard >> 100 box problem
(Message started by: Giannis Zertopoulis on Nov 29th, 2005, 11:16pm)

Title: 100 box problem
Post by Giannis Zertopoulis on Nov 29th, 2005, 11:16pm
There is a puzzle problem that hasn't anyone solve yet. Any help would be accepted!  ;)
There is a 10x10 table that has to be fullfilled with numbers from 1 to 100.
You begin from the upper left box with number 1.
horizontically and verically you move every three boxes, else every 2.
For example:
1 x x x x x x x x x
x x x x x x x x x x
x x x x x x x x x 10
2 x x x x x x x x x
x x x x x x x x x x
x x x x x x x x x 9
3 x x x x x x x x x
x x x x x x x 8 x x
x x x x x x x x x x
4 x x 5 x x 6 x x 7

We have managed to reach 99. Every solution given 100 would be nice!
Also accepted code that solves the problem.
E-mail me!

Title: Re: 100 box problem
Post by Barukh on Nov 29th, 2005, 11:18pm
Giannis, when you say "else every 2", you meand "diagonally", or other routes are also possible?

Title: Re: 100 box problem
Post by Giannis on Dec 2nd, 2005, 6:19am
I meant diagonally.. no other routes available!

Title: Re: 100 box problem
Post by Grimbal on Dec 2nd, 2005, 4:35pm
[hide]
00 13 54 01 14 55 22 05 56 23
33 65 98 34 64 97 35 63 96 36
74 40 15 75 39 04 76 38 21 77
99 12 53 02 82 87 25 06 57 24
32 66 73 85 49 72 84 62 95 37
91 41 16 88 26 03 81 27 20 78
70 11 52 71 83 86 48 07 58 45
31 67 92 30 50 93 29 61 94 28
90 42 17 89 43 18 80 44 19 79
69 10 51 68 09 60 47 08 59 46
[/hide]

Title: Re: 100 box problem
Post by JCJC454 on Dec 2nd, 2005, 5:00pm
Just a quick question Grimbal. Very nice answer but how did you get it? Im sure you didnt sit there going through all the different permutations. There must be some sequence or mathmatical answer to which I am interested to know.

Title: Re: 100 box problem
Post by Grimbal on Dec 3rd, 2005, 12:14pm
When I read the problem, I somehow froze, just sitting there, my eyes half-open, moving erratically, until the solution flashed in front of my eyes.  I did a print screen.

Just joking...

[hide]
I used a trick I found for the "knight riding around the chessboard" problem.  I created closed loops to cover the whole board and connected them by switching parallel steps.
One loop was going around the board (now 00-01-22-23-24-45-...).  Another loop was (04-15-16-...-21)  I replaced 01-22 and 21-04 with 01-04 and 21-22.  Then at 04-15 I connected another loop going (05-06-07-...-14).  I also replaced 01-04 by 01-02-03-04 to fill the center.  You can consider (02-03) to be a small loop.
Of course, the numbers were given after connecting all the loops.
This way of doing forces me to get back to where I started (99 is just one step away from 00), but that is usually asked as an extra difficulty.
[/hide]

Title: Re: 100 box problem
Post by Giannis on Dec 4th, 2005, 9:12am
Impressed! :o

;) Well i would really apreceate if i could have the source code please! Mail it or post it!!!

Title: Re: 100 box problem
Post by Grimbal on Dec 4th, 2005, 1:21pm
Source code?  Uh... I did it on paper. :P

Actually, I used excel to fill in the loops with increment formulas for the step number so that when I connect 2 loops, the steps are renumbered automatically.

Title: Re: 100 box problem
Post by Giannis on Dec 7th, 2005, 7:12am
Hello again!
I was trying to understand how you solved the problem, so I would like you to explain a little bit more the way and also tell me where can i find the
"knight riding around the chessboard" problem"" and its solution....



Powered by YaBB 1 Gold - SP 1.4!
Forum software copyright © 2000-2004 Yet another Bulletin Board