CS61B, Fall 2014 Project #2: Jumping Cubes(version 3) P. N. Hilfinger

Size: px
Start display at page:

Download "CS61B, Fall 2014 Project #2: Jumping Cubes(version 3) P. N. Hilfinger"

Transcription

1 CSB, Fall 0 Project #: Jumping Cubes(version ) P. N. Hilfinger Due: Tuesday, 8 November 0 Background The KJumpingCube game is a simple two-person board game. It is a pure strategy game, involving no element of chance. For this second project, you are to implement our version of this game, which we ll call jump, allowing a user to play against a computer or against another person, or to allow the computer to play itself. The basic interface is textual, as before, but for extra credit, you can produce a GUI interface for the game. Rules of Jump The game board consists of an N N array of squares, where N >. At any time, each square may have one of three colors: red, blue, or white (neutral), and some number of spots (as on dice). Initially, all squares are white and have one spot. For purposes of naming squares, we ll use the following notation: r : c refers to the square at row r and column c, where r,c N. Rows are numbered from top to bottom (top row is row ) and columns are numbered from the left. The neighbors of a square are the horizontally and vertically adjacent squares (diagonally adjacent squares are not neighbors). We say that a square is overfull if it contains more spots than it has neighbors. Thus, the four corner squares are overfull when they have more than two spots; other squares on the edge are overfull with more than three spots; and all others are overfull with more than four spots. There are two players, whom we ll call Red and Blue. The players each move in turn, with Red going first. A move consists of adding one spot on any square that does not have the opponent s color (so Red may add a spot to either a red or white square). A spot placed on any square colors that square with the player s color. After the player has moved, we repeat the following steps until no square is overfull or either all squares are red or all blue:. Pick an overfull square.. For each neighbor of the overfull square, move one spot out of the square and into the neighbor (even if occupied by the opposing side).. Give each of these neighboring squares the player s color (if they don t have it already). The order in which this happens, as it turns out, does not usually matter that is, the end result will be the same regardless of which overfull square s spots are removed first, with the exception that the winning position might differ. A player wins when all squares are the player s color. For example, given the board on the left (N = ) in Figure, if Red adds a spot to square :, we get the board on the right after all the spots stop jumping. Distributed under the GNU Public License as part of the KDE project. Copyright 999, 000 by Matthias Kiefer. It was inspired by an old game on the Commodore.

2 Project #: Jumping Cubes Red square: Blue square: Legend: Figure : Example of a move. The board on the right results from Red adding a spot at :. The rules hold that the game is over as soon as one player s color covers the board. This is a slightly subtle point: it is easy to set up situations where the procedure given above for dealing with overfull squares loops infinitely, swapping spots around in an endless cycle, unless one is careful to stop as soon as a winning position appears. It is acceptable, in fact, for you to report winning positions in which the redistribution procedure described above is prematurely terminated, so that some squares remain overfull. For example, if, on Red s move, the board is as on the left of Figure and Red moves to :, then the board will turn entirely red. You are allowed to stop the process of redistributing spots when all squares are red, even though, depending on the order in which you do things, you could end up with the board on the right in the figure. Textual Input Language Your program should respond to the following textual commands (you may add others). There is one command per line, but otherwise, whitespace may precede and follow command names and operands freely. Empty lines have no effect, and a command line whose first non-blank character is # is ignored as a comment. Extra arguments to a command (beyond those specified below) are ignored. An end-of-file indication on the command input should have the same effect as the quit command. clear Abandons the current game (if one is in progress), and clears the board to its initial

3 Project #: Jumping Cubes Figure : The board on the left shows a position just before Red s last move (to :). The board on the right is one possible stopping point for spot redistribution (all squares now being one color), even though the square at : is still overloaded. configuration (all squares neutral with one spot). Playing stops until the next start command. start Start playing from the current position, if not doing so already (has no effect if currently playing). Takes moves alternately from Red and Blue according to their color and the current total number of spots on the board: if the spot count plus the board size is even, it is Red s move, and if odd, Blue s move. quit Exits the program. auto P Stops the current game until the next start command and causes player P to be played by an automated player (an AI) on subsequent moves. The value P must be red or blue (ignore case Red or RED also work). Initially, Blue is an automated player. manual P Stops the current game until the next start command and causes player P to take moves from the terminal on subsequent moves. The value of P is as for the auto command. Initially, Red is a manual player. size N Stops any current game, clears the board to its initial configuration, and sets the size of the board to N squares, where N 0. Initially, N =. set R C N P Stop any current game. Put N spots at row R and column C (see.). P is either b or r (for blue or red,) indicating the color of the square. When N is 0, P is ignored and the square is cleared. N must be non-negative and less than or equal to the number of neighboring squares.

4 Project #: Jumping Cubes dump This command is especially for testing and debugging. It prints the board out in exactly the following format: === r - r r - b - - r - r - r r r r - b r r r r r b b r r r r b b b b r b b === with the === markers at the left margin and other lines indented four spaces. Here, - indicates a neutral square (necessarily with one spot), Nr indicates a red square with N spots, and Nb indicates a blue square with N spots. Don t use the two === markers anywhere else in your output. This gives the autograder a way to determine the state of your game board at any point. It does not change any of the state of the program. seed N If your program s automated players use pseudo-random numbers to choose moves, this command sets the random seed to N (a long integer). This command has no effect if there is no random component to your automated players (or if you don t use them in a particular game). It doesn t matter exactly how you use N as long as your automated player behaves identically each time it is seeded with N. In the absence of a seed command, do what you want to seed your generator. help Print a brief summary of the commands.. Entering Moves To enter moves from the terminal (for a manual player), use a command of the form R C Adds a spot to the square at row R, column C, where R and C are integers in the range to the current board size. Rows are numbered from the top, columns from the left. After the spot is added, spots are redistributed as indicated in the rules above. Like other commands, R and C may be surrounded by any amount of whitespace. Illegal moves must be rejected (they have no effect on the board; the program should tell the user that there is an error and request another move). The first and then every other move is for the red player, the second and then every other is for blue, and the normal legality rules apply to all moves. Output When either player enters a winning move, the program should print a line saying either "Red wins." or "Blue wins." as appropriate. Use exactly those phrases, and do not use them in any other context. When an AI plays, print out the moves that it makes using the format "P moves R C.", where P is "Red" or "Blue" and R and C are the row and column numbers at which a spot is added. Use exactly that format. Do not print this message for manual moves.

5 Project #: Jumping Cubes Finally, as indicated in, the dump command must print out in exactly the format shown. Otherwise, you are free to prompt for input however you want, and to print out whatever user-friendly output you wish (other than debugging output or Java exception tracebacks, that is). For example, you will probably want to print the game board out after each move is complete (this is distinct from printing the board in the special format required by dump ). When users enter erroneous input, you should print an error message, and the input should have no effect (and in particular, the user should be able to continue entering commands after an error). Make sure that any of this extra output you generate is distinct from the outputs that are required (otherwise, the testing software will flag your program as erroneous.) Regardless of whether users have made errors during a session, your program should always exit with code 0. Other Requirements On the instructional machines, the Unix command make must compile your program and make check must run all your tests (both unit and integration tests). The command java jump.main must run your program. In order to be submitted, your program will have to pass the style check. When testing your program, we will use the command java -ea jump.main to run it (the -ea insures that all assertions in your program are checked.) As before, we will evaluate your project in part on the thoroughness of your testing. Put JUnit test classes with names ending in Test (e.g., BoardTest.java) in your jump package, including one particular class named UnitTest, which should run all your individual JUnit tests as a suite (see the skeleton). Our autograder script will rununittest in the JUnit framework, expecting it to pass. For integration testing, we ve provided a program test-jump, which you can find on the instructional servers in the file ~csb/bin/test-jump. On Unix home systems (including Macs), you can simply copy this to a directory in your path and use it as you can on the instructional machines. This program allows you to run your program, supply it with input, and check the result, or to run two programs, and play them against each other (taking output like "Red moves " from one program and feeding its move to the other.) See the comments at the beginning of test-jump and the sample files in the skeleton tests directory for information on how to write your own tests. If you d prefer to substitute your own test driver instead, go ahead; just make sure you submit all necessary files and that you update your makefile appropriately. Your AI must reliably find a win from any position in which a forced win is four or fewer moves away, for any board no larger than six squares on a side. Likewise, it should be able to put off defeat for at least four moves (again on boards up to six squares on a side) if there is not a forced win for the other side in that many moves. Simply moving at random won t satisfy these requirements. Your program will have limited time to move. Don t expect to get more than an average of roughly seconds per move on the instructional servers. As always, your program must always be in control of its own termination. Terminating by means of an unhandled exception is never acceptable in a finished program.

6 Project #: Jumping Cubes You may add commands and other features to your program, as long as it otherwise meets this specification. If you do, be sure to update the output of the help command or of usage messages accordingly. Buffering. In order to make it possible for the autograder to interact properly with your program, you must make sure that required outputs that you produce get output immediately. Modern systems tend to buffer input or output collecting it until economies of scale make it efficient to deliver it to its destination. Furthermore, buffering is not consistent across file types: input from or output to a file may behave differently from input from and output to a terminal or Unix pipe. Buffering is problematic for an interactive program (there s no point in saving up all the prompts for input and only print them a thousand at a time.) To make sure this doesn t happen, make sure to use the flush() method on output files after writing a prompt or one of the outputs specified for this assignment. In fact, with the Java library there is no guarantee that the last outputs written to a file object actually get to their intended destination unless you explicitly close the file object, using the.close() method. So it s a good habit to close all output files before exiting, whether normally or as a result of an error. Extra Credit. For extra credit (and please attempt this only after you have met the required conditions,) you can provide a graphical interface. We ve set up the skeleton in such a way that you can use the simple strategy of having your GUI communicate with the rest of the program by writing the same commands you can enter by hand and interpreting the output from the program to get its moves. Your GUI must operate only when the program is executed with java jump.main --display (or java -ea ) so that the GUI is not initialized when the --display option is missing. Advice As usual, start immediately. Read the skeleton and try to understand its intent, even if you don t use it. We have deliberately included uses of various Java features in the skeleton in part to get you to explore them to read the on-line documentation and think about how they might be useful. We have provided a program staff-jump with a solution we ve developed. You can use it for ideas and sanity checks but it is NOT part of the specification! There might be errors in it for all we know (why, we might even have added a few just to mislead you.) Feel free to use it with test-jump to write tests of your program running against another.

2 Textual Input Language. 1.1 Notation. Project #2 2

2 Textual Input Language. 1.1 Notation. Project #2 2 CS61B, Fall 2015 Project #2: Lines of Action P. N. Hilfinger Due: Tuesday, 17 November 2015 at 2400 1 Background and Rules Lines of Action is a board game invented by Claude Soucie. It is played on a checkerboard

More information

UNIVERSITY OF CALIFORNIA Department of Electrical Engineering and Computer Sciences Computer Science Division. P. N. Hilfinger. Project #3: Checkers

UNIVERSITY OF CALIFORNIA Department of Electrical Engineering and Computer Sciences Computer Science Division. P. N. Hilfinger. Project #3: Checkers UNIVERSITY OF CALIFORNIA Department of Electrical Engineering and Computer Sciences Computer Science Division CS61B Fall 2004 P. N. Hilfinger Project #3: Checkers Due: 8 December 2004 1 Introduction Checkers

More information

Assignment 6 Play A Game: Minesweeper or Battleship!!! Due: Sunday, December 3rd, :59pm

Assignment 6 Play A Game: Minesweeper or Battleship!!! Due: Sunday, December 3rd, :59pm Assignment 6 Play A Game: Minesweeper or Battleship!!! Due: Sunday, December 3rd, 2017 11:59pm This will be our last assignment in the class, boohoo Grading: For this assignment, you will be graded traditionally,

More information

Pay attention to how flipping of pieces is determined with each move.

Pay attention to how flipping of pieces is determined with each move. CSCE 625 Programing Assignment #5 due: Friday, Mar 13 (by start of class) Minimax Search for Othello The goal of this assignment is to implement a program for playing Othello using Minimax search. Othello,

More information

Game Playing in Prolog

Game Playing in Prolog 1 Introduction CIS335: Logic Programming, Assignment 5 (Assessed) Game Playing in Prolog Geraint A. Wiggins November 11, 2004 This assignment is the last formally assessed course work exercise for students

More information

Eleventh Annual Ohio Wesleyan University Programming Contest April 1, 2017 Rules: 1. There are six questions to be completed in four hours. 2.

Eleventh Annual Ohio Wesleyan University Programming Contest April 1, 2017 Rules: 1. There are six questions to be completed in four hours. 2. Eleventh Annual Ohio Wesleyan University Programming Contest April 1, 217 Rules: 1. There are six questions to be completed in four hours. 2. All questions require you to read the test data from standard

More information

CPSC 217 Assignment 3

CPSC 217 Assignment 3 CPSC 217 Assignment 3 Due: Friday November 24, 2017 at 11:55pm Weight: 7% Sample Solution Length: Less than 100 lines, including blank lines and some comments (not including the provided code) Individual

More information

CMPS 12A Introduction to Programming Programming Assignment 5 In this assignment you will write a Java program that finds all solutions to the n-queens problem, for. Begin by reading the Wikipedia article

More information

CS151 - Assignment 2 Mancala Due: Tuesday March 5 at the beginning of class

CS151 - Assignment 2 Mancala Due: Tuesday March 5 at the beginning of class CS151 - Assignment 2 Mancala Due: Tuesday March 5 at the beginning of class http://www.clubpenguinsaraapril.com/2009/07/mancala-game-in-club-penguin.html The purpose of this assignment is to program some

More information

CPSC 217 Assignment 3 Due Date: Friday March 30, 2018 at 11:59pm

CPSC 217 Assignment 3 Due Date: Friday March 30, 2018 at 11:59pm CPSC 217 Assignment 3 Due Date: Friday March 30, 2018 at 11:59pm Weight: 8% Individual Work: All assignments in this course are to be completed individually. Students are advised to read the guidelines

More information

Taffy Tangle. cpsc 231 assignment #5. Due Dates

Taffy Tangle. cpsc 231 assignment #5. Due Dates cpsc 231 assignment #5 Taffy Tangle If you ve ever played casual games on your mobile device, or even on the internet through your browser, chances are that you ve spent some time with a match three game.

More information

Project 1: A Game of Greed

Project 1: A Game of Greed Project 1: A Game of Greed In this project you will make a program that plays a dice game called Greed. You start only with a program that allows two players to play it against each other. You will build

More information

CONTENTS. 1. Number of Players. 2. General. 3. Ending the Game. FF-TCG Comprehensive Rules ver.1.0 Last Update: 22/11/2017

CONTENTS. 1. Number of Players. 2. General. 3. Ending the Game. FF-TCG Comprehensive Rules ver.1.0 Last Update: 22/11/2017 FF-TCG Comprehensive Rules ver.1.0 Last Update: 22/11/2017 CONTENTS 1. Number of Players 1.1. This document covers comprehensive rules for the FINAL FANTASY Trading Card Game. The game is played by two

More information

In this project, you will create a memory game where you have to memorise and repeat a sequence of random colours!

In this project, you will create a memory game where you have to memorise and repeat a sequence of random colours! Memory Introduction In this project, you will create a memory game where you have to memorise and repeat a sequence of random colours! Step 1: Random colours First, let s create a character that can change

More information

Spring 06 Assignment 2: Constraint Satisfaction Problems

Spring 06 Assignment 2: Constraint Satisfaction Problems 15-381 Spring 06 Assignment 2: Constraint Satisfaction Problems Questions to Vaibhav Mehta(vaibhav@cs.cmu.edu) Out: 2/07/06 Due: 2/21/06 Name: Andrew ID: Please turn in your answers on this assignment

More information

Lab 7: 3D Tic-Tac-Toe

Lab 7: 3D Tic-Tac-Toe Lab 7: 3D Tic-Tac-Toe Overview: Khan Academy has a great video that shows how to create a memory game. This is followed by getting you started in creating a tic-tac-toe game. Both games use a 2D grid or

More information

For slightly more detailed instructions on how to play, visit:

For slightly more detailed instructions on how to play, visit: Introduction to Artificial Intelligence CS 151 Programming Assignment 2 Mancala!! The purpose of this assignment is to program some of the search algorithms and game playing strategies that we have learned

More information

Introduction to Artificial Intelligence CS 151 Programming Assignment 2 Mancala!! Due (in dropbox) Tuesday, September 23, 9:34am

Introduction to Artificial Intelligence CS 151 Programming Assignment 2 Mancala!! Due (in dropbox) Tuesday, September 23, 9:34am Introduction to Artificial Intelligence CS 151 Programming Assignment 2 Mancala!! Due (in dropbox) Tuesday, September 23, 9:34am The purpose of this assignment is to program some of the search algorithms

More information

a b c d e f g h i j k l m n

a b c d e f g h i j k l m n Shoebox, page 1 In his book Chess Variants & Games, A. V. Murali suggests playing chess on the exterior surface of a cube. This playing surface has intriguing properties: We can think of it as three interlocked

More information

Final Project: Reversi

Final Project: Reversi Final Project: Reversi Reversi is a classic 2-player game played on an 8 by 8 grid of squares. Players take turns placing pieces of their color on the board so that they sandwich and change the color of

More information

Computer Science 25: Introduction to C Programming

Computer Science 25: Introduction to C Programming California State University, Sacramento College of Engineering and Computer Science Computer Science 25: Introduction to C Programming Fall 2018 Project Dungeon Battle Overview Time to make a game a game

More information

CS 540-2: Introduction to Artificial Intelligence Homework Assignment #2. Assigned: Monday, February 6 Due: Saturday, February 18

CS 540-2: Introduction to Artificial Intelligence Homework Assignment #2. Assigned: Monday, February 6 Due: Saturday, February 18 CS 540-2: Introduction to Artificial Intelligence Homework Assignment #2 Assigned: Monday, February 6 Due: Saturday, February 18 Hand-In Instructions This assignment includes written problems and programming

More information

YourTurnMyTurn.com: chess rules. Jan Willem Schoonhoven Copyright 2018 YourTurnMyTurn.com

YourTurnMyTurn.com: chess rules. Jan Willem Schoonhoven Copyright 2018 YourTurnMyTurn.com YourTurnMyTurn.com: chess rules Jan Willem Schoonhoven Copyright 2018 YourTurnMyTurn.com Inhoud Chess rules...1 The object of chess...1 The board...1 Moves...1 Captures...1 Movement of the different pieces...2

More information

CS 312 Problem Set 6: λ-shark (CTF)

CS 312 Problem Set 6: λ-shark (CTF) CS 312 Problem Set 6: λ-shark (CTF) Assigned: April 15, 2004 Due: 11:59PM, May 6, 2004 Design review: April 26 27, 2004 Virtucon Corporation has discovered that the originally planned λ-shark game doesn

More information

CSE548, AMS542: Analysis of Algorithms, Fall 2016 Date: Sep 25. Homework #1. ( Due: Oct 10 ) Figure 1: The laser game.

CSE548, AMS542: Analysis of Algorithms, Fall 2016 Date: Sep 25. Homework #1. ( Due: Oct 10 ) Figure 1: The laser game. CSE548, AMS542: Analysis of Algorithms, Fall 2016 Date: Sep 25 Homework #1 ( Due: Oct 10 ) Figure 1: The laser game. Task 1. [ 60 Points ] Laser Game Consider the following game played on an n n board,

More information

Comprehensive Rules Document v1.1

Comprehensive Rules Document v1.1 Comprehensive Rules Document v1.1 Contents 1. Game Concepts 100. General 101. The Golden Rule 102. Players 103. Starting the Game 104. Ending The Game 105. Kairu 106. Cards 107. Characters 108. Abilities

More information

Lines of Action - Wikipedia, the free encyclopedia

Lines of Action - Wikipedia, the free encyclopedia 1 of 6 22/08/2008 10:42 AM Lines of Action Learn more about citing Wikipedia. From Wikipedia, the free encyclopedia Lines of Action is a two-player abstract strategy board game invented by Claude Soucie.

More information

In the game of Chess a queen can move any number of spaces in any linear direction: horizontally, vertically, or along a diagonal.

In the game of Chess a queen can move any number of spaces in any linear direction: horizontally, vertically, or along a diagonal. CMPS 12A Introduction to Programming Winter 2013 Programming Assignment 5 In this assignment you will write a java program finds all solutions to the n-queens problem, for 1 n 13. Begin by reading the

More information

OCTAGON 5 IN 1 GAME SET

OCTAGON 5 IN 1 GAME SET OCTAGON 5 IN 1 GAME SET CHESS, CHECKERS, BACKGAMMON, DOMINOES AND POKER DICE Replacement Parts Order direct at or call our Customer Service department at (800) 225-7593 8 am to 4:30 pm Central Standard

More information

Memory. Introduction. Scratch. In this project, you will create a memory game where you have to memorise and repeat a sequence of random colours!

Memory. Introduction. Scratch. In this project, you will create a memory game where you have to memorise and repeat a sequence of random colours! Scratch 2 Memory All Code Clubs must be registered. Registered clubs appear on the map at codeclubworld.org - if your club is not on the map then visit jumpto.cc/ccwreg to register your club. Introduction

More information

Would You Like To Earn $1000 s With The Click Of A Button?

Would You Like To Earn $1000 s With The Click Of A Button? Would You Like To Earn $1000 s With The Click Of A Button? (Follow these easy step by step instructions and you will) This e-book is for the USA and AU (it works in many other countries as well) To get

More information

CMSC 201 Fall 2018 Project 3 Sudoku

CMSC 201 Fall 2018 Project 3 Sudoku CMSC 201 Fall 2018 Project 3 Sudoku Assignment: Project 3 Sudoku Due Date: Design Document: Tuesday, December 4th, 2018 by 8:59:59 PM Project: Tuesday, December 11th, 2018 by 8:59:59 PM Value: 80 points

More information

3 0 S E C O N D Q U I C K S T A R T To start playing right away, read this page.

3 0 S E C O N D Q U I C K S T A R T To start playing right away, read this page. 3 0 S E C O N D Q U I C K S T A R T To start playing right away, read this page. STARTING/ Start with an empty board and decide who goes first and who s playing what color. OBJECT/ The object is to get

More information

The game consists of 3 rounds where you will build a castle in 30 seconds then place catapults and steal wall pieces from your neighbors.

The game consists of 3 rounds where you will build a castle in 30 seconds then place catapults and steal wall pieces from your neighbors. Story The king is dead Ok we ve all heard that one, there really isn t a story here. Just build a castle, fill it with as many walls and catapults as you can. Let s just have some fun with friends! Introduction

More information

Mind Ninja The Game of Boundless Forms

Mind Ninja The Game of Boundless Forms Mind Ninja The Game of Boundless Forms Nick Bentley 2007-2008. email: nickobento@gmail.com Overview Mind Ninja is a deep board game for two players. It is 2007 winner of the prestigious international board

More information

1 Modified Othello. Assignment 2. Total marks: 100. Out: February 10 Due: March 5 at 14:30

1 Modified Othello. Assignment 2. Total marks: 100. Out: February 10 Due: March 5 at 14:30 CSE 3402 3.0 Intro. to Concepts of AI Winter 2012 Dept. of Computer Science & Engineering York University Assignment 2 Total marks: 100. Out: February 10 Due: March 5 at 14:30 Note 1: To hand in your report

More information

BAPC The Problem Set

BAPC The Problem Set BAPC 2012 The 2012 Benelux Algorithm Programming Contest The Problem Set A B C D E F G H I J Another Dice Game Black Out Chess Competition Digit Sum Encoded Message Fire Good Coalition Hot Dogs in Manhattan

More information

Sudoku goes Classic. Gaming equipment and the common DOMINARI - rule. for 2 players from the age of 8 up

Sudoku goes Classic. Gaming equipment and the common DOMINARI - rule. for 2 players from the age of 8 up Sudoku goes Classic for 2 players from the age of 8 up Gaming equipment and the common DOMINARI - rule Board Sudoku goes classic is played on a square board of 6x6 fields. 4 connected fields of the same

More information

ENEE 150: Intermediate Programming Concepts for Engineers Spring 2018 Handout #7. Project #1: Checkers, Due: Feb. 19th, 11:59p.m.

ENEE 150: Intermediate Programming Concepts for Engineers Spring 2018 Handout #7. Project #1: Checkers, Due: Feb. 19th, 11:59p.m. ENEE 150: Intermediate Programming Concepts for Engineers Spring 2018 Handout #7 Project #1: Checkers, Due: Feb. 19th, 11:59p.m. In this project, you will build a program that allows two human players

More information

EXPLORING TIC-TAC-TOE VARIANTS

EXPLORING TIC-TAC-TOE VARIANTS EXPLORING TIC-TAC-TOE VARIANTS By Alec Levine A SENIOR RESEARCH PAPER PRESENTED TO THE DEPARTMENT OF MATHEMATICS AND COMPUTER SCIENCE OF STETSON UNIVERSITY IN PARTIAL FULFILLMENT OF THE REQUIREMENTS FOR

More information

Jarl 3 Freeman 3 Spearman Chieftain Vala Berserker

Jarl 3 Freeman 3 Spearman Chieftain Vala Berserker In the long winters between the glorious summers of raids and exploration, warriors scheme and keep their intellects sharp through games of wits and chance. Ragnar, Rollo, Floki and even the Earl challenge

More information

Analyzing Games: Solutions

Analyzing Games: Solutions Writing Proofs Misha Lavrov Analyzing Games: olutions Western PA ARML Practice March 13, 2016 Here are some key ideas that show up in these problems. You may gain some understanding of them by reading

More information

BINGO MANIAC. Developed by AYGENT543. Copyright Vishnu M Aiea

BINGO MANIAC. Developed by AYGENT543. Copyright Vishnu M Aiea BINGO MANIAC Developed by AYGENT543 Copyright 2013-2017 Vishnu M Aiea Information Program Name : BINGO MANIAC Program Type : Game, Executable Platform : Windows 32bit & 64bit Source Language : C (ISO 99)

More information

CSCE 2004 S19 Assignment 5. Halfway checkin: April 6, 2019, 11:59pm. Final version: Apr. 12, 2019, 11:59pm

CSCE 2004 S19 Assignment 5. Halfway checkin: April 6, 2019, 11:59pm. Final version: Apr. 12, 2019, 11:59pm CSCE 2004 Programming Foundations 1 Spring 2019 University of Arkansas, Fayetteville Objective CSCE 2004 S19 Assignment 5 Halfway checkin: April 6, 2019, 11:59pm Final version: Apr. 12, 2019, 11:59pm This

More information

Selected Game Examples

Selected Game Examples Games in the Classroom ~Examples~ Genevieve Orr Willamette University Salem, Oregon gorr@willamette.edu Sciences in Colleges Northwestern Region Selected Game Examples Craps - dice War - cards Mancala

More information

The game of Reversi was invented around 1880 by two. Englishmen, Lewis Waterman and John W. Mollett. It later became

The game of Reversi was invented around 1880 by two. Englishmen, Lewis Waterman and John W. Mollett. It later became Reversi Meng Tran tranm@seas.upenn.edu Faculty Advisor: Dr. Barry Silverman Abstract: The game of Reversi was invented around 1880 by two Englishmen, Lewis Waterman and John W. Mollett. It later became

More information

The 2013 British Informatics Olympiad

The 2013 British Informatics Olympiad Sponsored by Time allowed: 3 hours The 2013 British Informatics Olympiad Instructions You should write a program for part (a) of each question, and produce written answers to the remaining parts. Programs

More information

a b c d e f g h 1 a b c d e f g h C A B B A C C X X C C X X C C A B B A C Diagram 1-2 Square names

a b c d e f g h 1 a b c d e f g h C A B B A C C X X C C X X C C A B B A C Diagram 1-2 Square names Chapter Rules and notation Diagram - shows the standard notation for Othello. The columns are labeled a through h from left to right, and the rows are labeled through from top to bottom. In this book,

More information

e-bos TM Version 2.1.x PowerPlay User s Manual June BOS TM 2.1.x Page 1 of 59

e-bos TM Version 2.1.x PowerPlay User s Manual June BOS TM 2.1.x Page 1 of 59 e-bos TM Version 2.1.x Page 1 of 59 Important Notice This guide is delivered subject to the following conditions and restrictions: This guide contains proprietary information belonging to BK Entertainment.

More information

Intro to Java Programming Project

Intro to Java Programming Project Intro to Java Programming Project In this project, your task is to create an agent (a game player) that can play Connect 4. Connect 4 is a popular board game, similar to an extended version of Tic-Tac-Toe.

More information

Introduction to Spring 2009 Artificial Intelligence Final Exam

Introduction to Spring 2009 Artificial Intelligence Final Exam CS 188 Introduction to Spring 2009 Artificial Intelligence Final Exam INSTRUCTIONS You have 3 hours. The exam is closed book, closed notes except a two-page crib sheet, double-sided. Please use non-programmable

More information

Tac Due: Sep. 26, 2012

Tac Due: Sep. 26, 2012 CS 195N 2D Game Engines Andy van Dam Tac Due: Sep. 26, 2012 Introduction This assignment involves a much more complex game than Tic-Tac-Toe, and in order to create it you ll need to add several features

More information

Would You Like To Earn $1000 s With The Click Of A Button?

Would You Like To Earn $1000 s With The Click Of A Button? Would You Like To Earn $1000 s With The Click Of A Button? (Follow these easy step by step instructions and you will) This e-book is for the USA and AU (it works in many other countries as well) To get

More information

Assignment II: Set. Objective. Materials

Assignment II: Set. Objective. Materials Assignment II: Set Objective The goal of this assignment is to give you an opportunity to create your first app completely from scratch by yourself. It is similar enough to assignment 1 that you should

More information

Would You Like To Earn $1000 s With The Click Of A Button?

Would You Like To Earn $1000 s With The Click Of A Button? Would You Like To Earn $1000 s With The Click Of A Button? (Follow these easy step by step instructions and you will) - 100% Support and all questions answered! - Make financial stress a thing of the past!

More information

Programming Project 2

Programming Project 2 Programming Project 2 Design Due: 30 April, in class Program Due: 9 May, 4pm (late days cannot be used on either part) Handout 13 CSCI 134: Spring, 2008 23 April Space Invaders Space Invaders has a long

More information

CS Project 1 Fall 2017

CS Project 1 Fall 2017 Card Game: Poker - 5 Card Draw Due: 11:59 pm on Wednesday 9/13/2017 For this assignment, you are to implement the card game of Five Card Draw in Poker. The wikipedia page Five Card Draw explains the order

More information

03/05/14 20:47:19 readme

03/05/14 20:47:19 readme 1 CS 61B Project 2 Network (The Game) Due noon Wednesday, April 2, 2014 Interface design due in lab March 13-14 Warning: This project is substantially more time-consuming than Project 1. Start early. This

More information

G51PGP: Software Paradigms. Object Oriented Coursework 4

G51PGP: Software Paradigms. Object Oriented Coursework 4 G51PGP: Software Paradigms Object Oriented Coursework 4 You must complete this coursework on your own, rather than working with anybody else. To complete the coursework you must create a working two-player

More information

Game components. Common components: 1 dice tower. 24 progress tokens. 40 commodity tokens 8 of each type

Game components. Common components: 1 dice tower. 24 progress tokens. 40 commodity tokens 8 of each type Follow the lead of the famous navigator and discoverer Amerigo Vespucci. New lands are waiting to be discovered and to provide a new homeland rich with valuable resources ffor its settlers. Good planning

More information

Cato s Hike Quick Start

Cato s Hike Quick Start Cato s Hike Quick Start Version 1.1 Introduction Cato s Hike is a fun game to teach children and young adults the basics of programming and logic in an engaging game. You don t need any experience to play

More information

Documentation and Discussion

Documentation and Discussion 1 of 9 11/7/2007 1:21 AM ASSIGNMENT 2 SUBJECT CODE: CS 6300 SUBJECT: ARTIFICIAL INTELLIGENCE LEENA KORA EMAIL:leenak@cs.utah.edu Unid: u0527667 TEEKO GAME IMPLEMENTATION Documentation and Discussion 1.

More information

The Mathematics of Playing Tic Tac Toe

The Mathematics of Playing Tic Tac Toe The Mathematics of Playing Tic Tac Toe by David Pleacher Although it has been shown that no one can ever win at Tic Tac Toe unless a player commits an error, the game still seems to have a universal appeal.

More information

Spring 06 Assignment 2: Constraint Satisfaction Problems

Spring 06 Assignment 2: Constraint Satisfaction Problems 15-381 Spring 06 Assignment 2: Constraint Satisfaction Problems Questions to Vaibhav Mehta(vaibhav@cs.cmu.edu) Out: 2/07/06 Due: 2/21/06 Name: Andrew ID: Please turn in your answers on this assignment

More information

1, 2,, 10. Example game. Pieces and Board: This game is played on a 1 by 10 board. The initial position is an empty board.

1, 2,, 10. Example game. Pieces and Board: This game is played on a 1 by 10 board. The initial position is an empty board. ,,, 0 Pieces and Board: This game is played on a by 0 board. The initial position is an empty board. To Move: Players alternate placing either one or two pieces on the leftmost open squares. In this game,

More information

Problem F. Chessboard Coloring

Problem F. Chessboard Coloring Problem F Chessboard Coloring You have a chessboard with N rows and N columns. You want to color each of the cells with exactly N colors (colors are numbered from 0 to N 1). A coloring is valid if and

More information

CMPUT 657: Heuristic Search

CMPUT 657: Heuristic Search CMPUT 657: Heuristic Search Assignment 1: Two-player Search Summary You are to write a program to play the game of Lose Checkers. There are two goals for this assignment. First, you want to build the smallest

More information

Chess Handbook: Course One

Chess Handbook: Course One Chess Handbook: Course One 2012 Vision Academy All Rights Reserved No Reproduction Without Permission WELCOME! Welcome to The Vision Academy! We are pleased to help you learn Chess, one of the world s

More information

Problem 4.R1: Best Range

Problem 4.R1: Best Range CSC 45 Problem Set 4 Due Tuesday, February 7 Problem 4.R1: Best Range Required Problem Points: 50 points Background Consider a list of integers (positive and negative), and you are asked to find the part

More information

INTRODUCTION TO COMPUTER SCIENCE I PROJECT 6 Sudoku! Revision 2 [2010-May-04] 1

INTRODUCTION TO COMPUTER SCIENCE I PROJECT 6 Sudoku! Revision 2 [2010-May-04] 1 INTRODUCTION TO COMPUTER SCIENCE I PROJECT 6 Sudoku! Revision 2 [2010-May-04] 1 1 The game of Sudoku Sudoku is a game that is currently quite popular and giving crossword puzzles a run for their money

More information

CS106X Handout 13 Winter 2018 January 24 th, 2018 Assignment 3: Boggle

CS106X Handout 13 Winter 2018 January 24 th, 2018 Assignment 3: Boggle CS106X Handout 13 Winter 2018 January 24 th, 2018 Assignment 3: Boggle Thanks to Todd Feldman for the original assignment idea. And thanks to Julie Zelenski and Eric Roberts for the handout. The Game of

More information

BMT 2018 Combinatorics Test Solutions March 18, 2018

BMT 2018 Combinatorics Test Solutions March 18, 2018 . Bob has 3 different fountain pens and different ink colors. How many ways can he fill his fountain pens with ink if he can only put one ink in each pen? Answer: 0 Solution: He has options to fill his

More information

A fun way to challenge your math thinking! Grade Levels: 4th - 8th Time: 1 class period. Check out 36 BINGO Snapshot

A fun way to challenge your math thinking! Grade Levels: 4th - 8th Time: 1 class period. Check out 36 BINGO Snapshot Grade Levels: 4th - 8th Time: 1 class period A computation strategy game Check out 36 BINGO Snapshot What equations can you make with 4, 5, & 6? (6 X 4) 5 = 19 6 + 4 + 5 = 15 (6 5) + 4 = 5 Which equation

More information

1 Running the Program

1 Running the Program GNUbik Copyright c 1998,2003 John Darrington 2004 John Darrington, Dale Mellor Permission is granted to make and distribute verbatim copies of this manual provided the copyright notice and this permission

More information

Find the items on your list...but first find your list! Overview: Definitions: Setup:

Find the items on your list...but first find your list! Overview: Definitions: Setup: Scavenger Hunt II A game for the piecepack by Brad Lackey. Version 1.1, 29 August 2006. Copyright (c) 2005, Brad Lackey. 4 Players, 60-80 Minutes. Equipment: eight distinct piecepack suits. Find the items

More information

Board Game AIs. With a Focus on Othello. Julian Panetta March 3, 2010

Board Game AIs. With a Focus on Othello. Julian Panetta March 3, 2010 Board Game AIs With a Focus on Othello Julian Panetta March 3, 2010 1 Practical Issues Bug fix for TimeoutException at player init Not an issue for everyone Download updated project files from CS2 course

More information

GLOSSARY USING THIS REFERENCE THE GOLDEN RULES ACTION CARDS ACTIVATING SYSTEMS

GLOSSARY USING THIS REFERENCE THE GOLDEN RULES ACTION CARDS ACTIVATING SYSTEMS TM TM USING THIS REFERENCE This document is intended as a reference for all rules queries. It is recommended that players begin playing Star Wars: Rebellion by reading the Learn to Play booklet in its

More information

Problem A To and Fro (Problem appeared in the 2004/2005 Regional Competition in North America East Central.)

Problem A To and Fro (Problem appeared in the 2004/2005 Regional Competition in North America East Central.) Problem A To and Fro (Problem appeared in the 2004/2005 Regional Competition in North America East Central.) Mo and Larry have devised a way of encrypting messages. They first decide secretly on the number

More information

Computing Science (CMPUT) 496

Computing Science (CMPUT) 496 Computing Science (CMPUT) 496 Search, Knowledge, and Simulations Martin Müller Department of Computing Science University of Alberta mmueller@ualberta.ca Winter 2017 Part I Intro - Problem Solving for

More information

My Little Pony CCG Comprehensive Rules

My Little Pony CCG Comprehensive Rules Table of Contents 1. Fundamentals 101. Deckbuilding 102. Starting a Game 103. Winning and Losing 104. Contradictions 105. Numeric Values 106. Players 2. Parts of a Card 201. Name 202. Power 203. Color

More information

After learning the Rules, What should beginners learn next?

After learning the Rules, What should beginners learn next? After learning the Rules, What should beginners learn next? Chess Puzzling Presentation Nancy Randolph Capital Conference June 21, 2016 Name Introduction to Chess Test 1. How many squares does a chess

More information

OBJECTIVE OF THE GAME YOUR TEAM COMPONENTS. speeds and Blocker pushing.

OBJECTIVE OF THE GAME YOUR TEAM COMPONENTS. speeds and Blocker pushing. OBJECTIVE OF THE GAME Impact City Roller Derby (ICRD) is a fast-paced board game based on flat track roller derby. The objective of the game is to score more points than your opponent by passing opposing

More information

Stat 155: solutions to midterm exam

Stat 155: solutions to midterm exam Stat 155: solutions to midterm exam Michael Lugo October 21, 2010 1. We have a board consisting of infinitely many squares labeled 0, 1, 2, 3,... from left to right. Finitely many counters are placed on

More information

Copies of the Color by Pixel template sheets (included in the Resources section). Colored pencils, crayons, markers, or other supplies for coloring.

Copies of the Color by Pixel template sheets (included in the Resources section). Colored pencils, crayons, markers, or other supplies for coloring. This offline lesson plan covers the basics of computer graphics. After learning about how graphics work, students will create their own Color by Pixel programs. The lesson plan consists of four parts,

More information

For our EC331 project we successfully designed and implemented a PIC based Tic-Tac-Toe game using the PIC16874.

For our EC331 project we successfully designed and implemented a PIC based Tic-Tac-Toe game using the PIC16874. EC331 Project Report To: Dr. Song From: Colin Hill and Peter Haugen Date: 6/7/2004 Project: Pic based Tic-Tac-Toe System Introduction: For our EC331 project we successfully designed and implemented a PIC

More information

ENGR170 Assignment Problem Solving with Recursion Dr Michael M. Marefat

ENGR170 Assignment Problem Solving with Recursion Dr Michael M. Marefat ENGR170 Assignment Problem Solving with Recursion Dr Michael M. Marefat Overview The goal of this assignment is to find solutions for the 8-queen puzzle/problem. The goal is to place on a 8x8 chess board

More information

--- ISF Game Rules ---

--- ISF Game Rules --- --- ISF Game Rules --- 01 Definition and Purpose 1.1 The ISF Game Rules are standard criteria set by the International Stratego Federation (ISF), which (together with the ISF Tournament Regulations) have

More information

Introduction to Counting and Probability

Introduction to Counting and Probability Randolph High School Math League 2013-2014 Page 1 If chance will have me king, why, chance may crown me. Shakespeare, Macbeth, Act I, Scene 3 1 Introduction Introduction to Counting and Probability Counting

More information

Essential Chess Basics (Updated Version) provided by Chessolutions.com

Essential Chess Basics (Updated Version) provided by Chessolutions.com Essential Chess Basics (Updated Version) provided by Chessolutions.com 1. Moving Pieces In a game of chess white has the first move and black moves second. Afterwards the players take turns moving. They

More information

Welcome to the Brain Games Chess Help File.

Welcome to the Brain Games Chess Help File. HELP FILE Welcome to the Brain Games Chess Help File. Chess a competitive strategy game dating back to the 15 th century helps to developer strategic thinking skills, memorization, and visualization of

More information

Microchess 2.0 gives you a unique and exciting way to use your Apple II to enjoy the intellectually stimulating game of chess. The complete program lo

Microchess 2.0 gives you a unique and exciting way to use your Apple II to enjoy the intellectually stimulating game of chess. The complete program lo I Microchess 2.0 gives you a unique and exciting way to use your Apple II to enjoy the intellectually stimulating game of chess. The complete program logic to play a very skillful game of chess, as well

More information

G52CPP Lab Exercise: Hangman Requirements (v1.0)

G52CPP Lab Exercise: Hangman Requirements (v1.0) G52CPP Lab Exercise: Hangman Requirements (v1.0) 1 Overview This is purely an exercise that you can do for your own interest. It will not affect your mark at all. You can do as little or as much of it

More information

Programming Assignment 4

Programming Assignment 4 Programming Assignment 4 Due: 11:59pm, Saturday, January 30 Overview The goals of this section are to: 1. Use methods 2. Break down a problem into small tasks to implement Setup This assignment requires

More information

DELUXE 3 IN 1 GAME SET

DELUXE 3 IN 1 GAME SET Chess, Checkers and Backgammon August 2012 UPC Code 7-19265-51276-9 HOW TO PLAY CHESS Chess Includes: 16 Dark Chess Pieces 16 Light Chess Pieces Board Start Up Chess is a game played by two players. One

More information

ARMY COMMANDER - GREAT WAR INDEX

ARMY COMMANDER - GREAT WAR INDEX INDEX Section Introduction and Basic Concepts Page 1 1. The Game Turn 2 1.1 Orders 2 1.2 The Turn Sequence 2 2. Movement 3 2.1 Movement and Terrain Restrictions 3 2.2 Moving M status divisions 3 2.3 Moving

More information

Red Dragon Inn Tournament Rules

Red Dragon Inn Tournament Rules Red Dragon Inn Tournament Rules last updated Aug 11, 2016 The Organized Play program for The Red Dragon Inn ( RDI ), sponsored by SlugFest Games ( SFG ), follows the rules and formats provided herein.

More information

Game Rules. 01 Definition and Purpose. 03 Overlooking ISF Game Rules: ISF Court of Appeal. 02 Changes in ISF Game Rules.

Game Rules. 01 Definition and Purpose. 03 Overlooking ISF Game Rules: ISF Court of Appeal. 02 Changes in ISF Game Rules. 01 Game Rules Game Rules 01 Definition and Purpose 1.1 The ISF Game Rules are standard criteria set by the International Stratego Federation (ISF), which (together with the ISF Tournament Regulations)

More information

Movement of the pieces

Movement of the pieces Movement of the pieces Rook The rook moves in a straight line, horizontally or vertically. The rook may not jump over other pieces, that is: all squares between the square where the rook starts its move

More information

Problem C The Stern-Brocot Number System Input: standard input Output: standard output

Problem C The Stern-Brocot Number System Input: standard input Output: standard output Problem C The Stern-Brocot Number System Input: standard input Output: standard output The Stern-Brocot tree is a beautiful way for constructing the set of all nonnegative fractions m / n where m and n

More information

CSC Curriculum Term One Lesson Plans

CSC Curriculum Term One Lesson Plans CSC Curriculum Term One Lesson Plans Core Lesson 1: The Pawn Move Learning Objectives To learn about the chess board, and how pawns move and capture. To play a game in which you win by getting a pawn to

More information