Here are some of the solutions from our 2-hour noughts and crosses challenge code night.
This was from one of our regular coding nights, so the goals are:
- Code something cool
- Learn something
- Teach something
- Most importantly - Have fun!
We will be implementing a version of the game Noughts & Crosses, also known as tic-tac-toe, in the browser. Ideally everyone will work in pairs, but this is not a strict rule. There are no restrictions on languages (JavaScript, TypeScript, etc.), framework (Vanilla, React, etc.) or libraries. Participants are encouraged to share what they produce on our GitHub so others can see what we get up to and potentially join us.
7:00pm Arrival, team forming, planning
7:30pm Start coding
9:30pm Present projects & scoring
10:00pm Winner declared
The minimum criteria is:
- A game playable by two players using the same browser.
- The game is played on a 3x3 grid.
- Each click alternates alternatively adds an X or an O.
- When a line of 3 X or O are connected in a straight line (orthagonal or diagonal) that player is declared the winner.
- If all spaces are filled without a line of 3 the game is declared a draw.
- Select the size of the grid to play on.
- Active player identifier.
- Reset game button.
- Score counter across games.
- Keyboard interface
We will score each project individually in the following criteria out of ten, then take an average across the group:
Did this team meet the minimum spec?
Is the code the produced easy to understand?
Does the project look nice?
How many extra features are implemented?
Did the team put in a lot of effort? (based on experience, language chosen, difficulties encountered, etc.)