Java - PuzzleManiac - Naive

Naive

This algorithm does it the hard way. It places all the bricks together on the board, wether they fit or not. This very often results in situations that are far from correct. When the computer notices his mistake it rearranges the bricks trying to fix his mistake.
This procedure goes on until it finds a solution. When the program runs you'll see how the bricks are moved around the board in a systematic way until they all fit in. The computer always assumes that the brick it last placed is the one that's causing the problem so this brick is moving all the time. The others move only once and a while. You will never want to use this algorithm to solve a puzzle unless you want to die before the program finds the solution (I don't think they've got computers in heaven yet). You'd better take a look at these algorithms.

Demonstration


This page contains nice Java applets, but your browser is to stupid to display them... Go and get a new one !!!



The algorithms are written in Prolog by H. Vandecasteele.

Project verslag

PuzzleManiac page

Home