google how to solve jigsaw, that gives you a good algorithm to solve any jigsaw. :) basically start with the lowest row and than do the right most line, and than you only have a smaller jigsaw to finish, continue with doing the lowest row of the stuff you have yet to solve, and than the rightmost line again.