View Single Post
Old May 25th, 2006, 8:05 AM   #33
megamind5005
Programmer
 
megamind5005's Avatar
 
Join Date: Dec 2004
Location: UK
Posts: 53
Rep Power: 4 megamind5005 is on a distinguished road
I was just thinking, how about make a version of the Towers of Hanoi game? If you don't know about it, google spews out hundreds of good pages on it.

I'm thinking you can record the position of each disk and redraw a graphical representation using ASCII art (unless you're very good at GUI) everytime a change is made. Then you can either have a user give commands as to put what where, but also have a traced solution.

This is a classic problem used in many computer science books so you'll probably come across an algorithm to solve the problem fairly soon, but this algorithm is very general. The interesting part will be how you implement it in a command line interface. You could even take up the suggestion of using classes (e.g. disk objects etc).

I'd do this myself too, if it wasn't for my upcoming exams
__________________
Tetris is so unrealistic
megamind5005 is offline   Reply With Quote