Puzzle problem! - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

Puzzle problem!

ThandiThandi Posts: 2Member
Please Help me Solve this Puzzle game.I 'm required to write a Javascript Programe,Of 15-Puzzle number game. There is 4-by-4 board (implemented as an XHTML table)for a total of 16 slots.One of the slots is empty.The other slots are occupied by 15 tiles, randomly numbered from 1 through 15. Any tile next to the currently empty slot can be moved into the currently empty slot by clicking on the tile. This program should create the board with the tiles out of order. The user's goal is to arrange the tiles into sequencial order row by row. Using the DHTML object model and the onclick event, write a script that allows the user to swap the positions of the open position of the adjacent tile. Enjoy this challange!
Sign In or Register to comment.