Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

Game Tree - Exercise 12 | Data Structure and Algorithms | CS 303, Assignments of Computer Science

Material Type: Assignment; Class: Algorithms and Data Structures; Subject: Computer Science; University: University of Alabama - Birmingham; Term: Spring 2008;

Typology: Assignments

2009/2010

Uploaded on 04/12/2010

koofers-user-xc2-1
koofers-user-xc2-1 🇺🇸

10 documents

1 / 2

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
CS 303L Data Structure and Algorithm Lab
April 3, 2008
Exercise 12
Goal:
Understand game tree
Tasks:
A game tree is a graphical representation of the game. We may
consider a game tree is a directed graph whose nodes are positions in
a game and whose edges are moves. The complete game tree for a
game is the game tree starting at the initial position and containing
all possible moves from each position.
Tic-Tac-Toe is a two-player game. In this game, O and X symbols
are used to represent the two players respectively. For each turn,
players will mark their symbol in a 3×3 grid. The player who succeeds
in placing three respective marks in a horizontal, vertical or diagonal
row wins the game.
pf2

Partial preview of the text

Download Game Tree - Exercise 12 | Data Structure and Algorithms | CS 303 and more Assignments Computer Science in PDF only on Docsity!

CS 303L Data Structure and Algorithm Lab

April 3, 2008

Exercise 12

Goal:

Understand game tree

Tasks:

A game tree is a graphical representation of the game. We may consider a game tree is a directed graph whose nodes are positions in a game and whose edges are moves. The complete game tree for a game is the game tree starting at the initial position and containing all possible moves from each position. “Tic-Tac-Toe” is a two-player game. In this game, O and X symbols are used to represent the two players respectively. For each turn, players will mark their symbol in a 3×3 grid. The player who succeeds in placing three respective marks in a horizontal, vertical or diagonal row wins the game.

CS 303L Data Structure and Algorithm Lab

April 3, 2008

In this exercise, you need to build a game tree for “Tic-Tac-Toe”. The game tree will be used in the Programming Assignment 6 for computer to decide its movement.

You may refer to the following links to see a demonstration of the Tic-Tac-Toe.

http://rintintin.colorado.edu/~epperson/Java/TicTacToe.html