Due: Thursday January 21, 11pm.
For this assignment, you have to implement a game of tic-tac-toe. On the device there need to be the following elements:
The buttons in the 3x3 grid are initially blank / gray / ... . When you press a gray button, alternatively symbols X and O appear on the buttons you press, allowing you to play the game (so the activity has to keep track of the turn). Pressing buttons already containing X or O has no effect. When three buttons in a row contain the same symbol, you highlight the row in some way, and you declare the game outcome. Otherwise, if the grid is full but there are no three in a row, you declare a tie.
It's up to you how to highlight the three in a row. A possible way consists in using different images -- say, X and O with different color or background. Another possibility is to use X and O icons that are pngs that are transparent outside of the X and O strokes, and use the background attribute of ImageButtons to set and change the background of the buttons to hilight and "normallight" the buttons.
Also give your application a descriptive icon (the ic_launcher icon).
As a starting point, you can take the code we developed in Lecture 3, but you don't have to do so.