Friday Fun: PowerShell Noughts and Crosses (Tic-Tac-Toe)
OK, we all know it’s really called Noughts and Crosses, but to keep the search engines happy this is about Tic-Tac-Toe. While expanding my programming skills with another language I went through an exercise in this excellent book to create a Tic-Tac-Toe game. While at a loose end one evening, I thought I would take the logic, port it to PowerShell and add a few extra features. Nothing particularly clever in here, rather it’s an encouragement to break your code down into manageable functions.
Oh and thanks to SoapyFrog for the code to make PowerShell ASCII Art….
Note:
- PowerShell v3.0 is required, you can get that from here if you are not on that version.
- It must be run from the PowerShell default console, not the ISE console.
- Make sure you have the sound turned on :-)
I’m off to see if I can get it take on a Nuclear Missile Launching Program….