Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Kangaroo problem, np complete :)
#3
Agamemnus,
The solution is fairly straight foreward. Your comment about starting with simple cases is a good general strategy, and worked well for me here. The code took me longer to write than I would like to admit. It would be nice to see some others try this problem, so I am PMing my solution and code to you. Feel free to post them.

Xhantt,
The kangaroos can only move straight forward one space(hop) or two spaces (jump). This all you need to worry about. By moving them one or two spaces, you will either solve the problem or create a road block.
hrist Jesus came into the world to save sinners, of whom I am first.(I Timothy 1:15)

For God so loved the world, that He gave His only begotten Son,
that whoever believes in Him should not perish, but have eternal life.(John 3:16)
Reply


Messages In This Thread
Kangaroo problem, np complete :) - by Agamemnus - 08-02-2003, 10:58 PM
Kangaroo problem, np complete :) - by xhantt - 08-03-2003, 12:32 AM
kangaroo problem - by SCM - 08-04-2003, 06:15 AM
Kangaroo problem, np complete :) - by na_th_an - 08-04-2003, 07:18 AM
kangaroo challenge - by SCM - 08-05-2003, 03:09 AM
Re: kangaroo challenge - by Phydaux - 08-05-2003, 06:04 AM
Kangaroo problem, np complete :) - by Agamemnus - 08-05-2003, 07:20 PM
Kangaroo problem, np complete :) - by Lanzaa - 08-06-2003, 02:46 AM
Kangaroo problem - by SCM - 08-06-2003, 11:20 AM
Kangaroo problem, np complete :) - by Agamemnus - 08-09-2003, 04:51 AM
Kangaroo problem, np complete :) - by Lanzaa - 10-03-2003, 06:01 AM
Kangaroo problem, np complete :) - by Agamemnus - 10-03-2003, 06:17 AM
Kangaroo problem, np complete :) - by Lanzaa - 10-03-2003, 06:41 AM
Kangaroo problem, np complete :) - by Agamemnus - 10-03-2003, 06:47 AM
Kangaroo problem - by SCM - 10-03-2003, 07:31 AM
Kangaroo problem, np complete :) - by Lanzaa - 10-03-2003, 07:57 AM
Kangaroo problem, np complete :) - by SCM - 10-03-2003, 08:10 AM
Kangaroo problem, np complete :) - by Lanzaa - 10-03-2003, 08:19 AM
Kangaroo problem, np complete :) - by SCM - 10-03-2003, 11:26 PM
Kangaroo problem, np complete :) - by Agamemnus - 10-04-2003, 03:55 AM
Re: Kangaroo problem, np complete :) - by Clippy - 07-12-2009, 01:05 AM
Re: Kangaroo problem, np complete :) - by LPG - 10-30-2009, 08:21 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)