mirror of
https://github.com/nelsbrock/dev-tictactoe.git
synced 2026-08-14 20:56:49 +02:00
initial commit
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
#ifndef __TICTACTOE_GAME_H__
|
||||
#define __TICTACTOE_GAME_H__
|
||||
|
||||
#include <linux/types.h>
|
||||
|
||||
typedef struct tictactoe_game {
|
||||
char next_turn;
|
||||
char winner;
|
||||
char board[3][3];
|
||||
} ttt_game_t;
|
||||
|
||||
int tictactoe_game_init(ttt_game_t *game);
|
||||
char tictactoe_game_check_winner(ttt_game_t *game);
|
||||
int tictactoe_game_make_turn(ttt_game_t *game, size_t x, size_t y);
|
||||
int tictactoe_game_snprint(ttt_game_t *game, char *buf, size_t len);
|
||||
|
||||
#endif // __TICTACTOE_GAME_H__
|
||||
Reference in New Issue
Block a user