This challenge is generally based upon, related to, or simulates game or some portion of one.

learn more… | top users | synonyms

3
votes
1answer
997 views

Optimal Minesweeper on the Largest Board

Overview: Your challenge is to write a program that will play minesweeper optimally, giving the best move in any position. Moreover, you must do this on the largest board possible. Game details: ...
0
votes
1answer
318 views

Babylon.js - loop through a scene and apply a simple fragment shader to all of the objects

You have a library - a fully loaded 2014 Babylon.js. You have a fragment shader - let's call it sample.fragment.fx. You have a scene - loaded ahead of time, possibly from a .babylon JSON file. Your ...
2
votes
1answer
953 views

A Most Excellent Code Golf Adventure

You dudes, the Most Excellent Adventure is a home brew roleplaying game system based on the Bill & Ted Films, plays gnarly air guitar riff. In this game system, when you draw from your dice pool ...
14
votes
25answers
3k views

Determine win in Tictactoe

Let's play some code golf! Given a tic-tac-toe board state (Example:) |x|x|o| |x|o|x| |o|o|x| Determine whether a game is a win a lose or cat. Your code should output any of these options given a ...
18
votes
2answers
1k views

Mastermind strategy

I could only find code-golf challenges for Mastermind, so here's a code-challenge version that I would have liked to take on myself. An optimal strategy for the normal Mastermind game, MM(4,6), was ...
13
votes
3answers
915 views

Guess the word (aka Lingo)

The goal of this challenge is to write a program able to guess a word in the smallest possible number of attempts. It is based on the concept of the Lingo TV show ...
11
votes
2answers
906 views

Frogger-ish game

How about giving the good ol' arcade game Frogger a revival, Code Golf-style! Your task is to create a version of this classic game, with as few characters of code as possible. Use the language of ...
32
votes
7answers
2k views

Hunt the Wumpus

When I was a lad, kids would wander into computer stores and play Hunt the Wumpus until the staff kicked us out. It was a simple game, programmable on the home computers of the mid-1970s, machines so ...
17
votes
3answers
2k views

aHHHH! The Beasts are HHHHere!

As we learned from the IBM PC AT, YouTube (see video), Wikipedia (see article), and Sesame Street: The letter H is the most merciless letter of the alphabet! (Even when actually composed from two ...
23
votes
6answers
1k views

Write a Hangman Solver

You are required to write a Hangman solver. Testing against this English word list[1], the solver that solves the most number of words wins, with the number of total incorrect guesses being the ...
11
votes
4answers
557 views

Compare two poker hands

Challenge: Given two five-card hands, determine which one wins by the standard ranking of poker hands. Input: Ten cards separated by spaces from stdin or as command line arguments, whichever you ...
13
votes
5answers
980 views

Create a Simon Clone!

Scenario: while programming you have a sudden nostalgic urge for the '80s and cheesy games. Requirements: Make a GUI program (text probably won't work) for Simon, the game. Input can be clicking, or ...
20
votes
4answers
2k views

Solve Aristotle's Number Problem

Aristotle's number puzzle is the challenge of populating each of 19 cells in a hexagonal grid with a unique integer between 1 and 19 such that the total along every axis is 38. You can picture the ...
5
votes
4answers
715 views

A golfed golfing game

You have to make a golf game with the following specification :- The field is 10 X 10 characters without spaces. Free ground is represented by . A hole generated at random(not at 0,0) is shown by O ...
34
votes
7answers
15k views

Create a simple 2048 game clone

2048 is an incredibly fun and addictive game in which the goal is to create a tile with 2048 on it. Here's a short description of the game: Pressing an arrow key will slide all the blocks in the ...
25
votes
1answer
851 views

Minesweeper Solver

We already generated Minesweeper fields, but someone really has to sweep those generated mines before PCG blows up! Your task is to write a Minesweeper Solver that is compatible with a slightly ...
10
votes
5answers
591 views

Name the poker hand - 7 cards edition

The Challenge: In this question: Name the poker hand you had to take a five card poker hand and identify it. This question is similar, with two twists: First, the output will be in all lower case. ...
2
votes
1answer
237 views

Hidden easter egg [closed]

Here's a fun idea: Write a simple game (tic-tac-toe, guess the number, etc) that has an easter egg in it, that can be triggered by a specific, special input from the user and does something cool, but ...
19
votes
5answers
2k views

Flappy Bird Clones :)

Everyone's been freaking out about that stupid "Flappy Bird" game being removed. So, your task is to crate a Flappy Bird Clone game. Its really simple. Here are the guide lines: It can use either ...
6
votes
1answer
368 views

Graphical, networked, two-(human)-player Tic-Tac-Toe

Create a Tic-Tac-Toe game that allows two human players to play against each other using two networked devices. Requirements: Network play. Program must let both players know whose turn it is. ...
2
votes
0answers
304 views

Find the best path in a “match-3” game

Suppose you want to cheat in a "match-3" game. In this "match-3" game: In each turn you can move a gem along a path. For example, you can move a gem right-right-down, as in A. (The gems are ...
18
votes
4answers
887 views

Tennis scores meets Code Golf

In light of the 2014 Australian Open in Melbourne, and the win by Stanislas Wawrinka against Novak Djokovic, I propose the following code golf challenge! Wawrinka and Djokovic are at it again for the ...
10
votes
1answer
259 views

Find the best immediate move in a “match-3” game

Your challenge today is to take input like this: fbcfbee ffcabbe debceec bccabbe edcfbcd daeaafc eebcbeb And output the best possible move in a Bejeweled-like game that will match three or more ...
3
votes
2answers
216 views

Simple One Game Blackjack

This is a very stripped down version of A BlackJack KOTH contest... This is the goal: Upon the execution: There are two inputs, "H" to hit (have the code deal a card), "S" to stand (Stop getting ...
14
votes
28answers
1k views

Even or odd: three player

It's a three players game, play with one hand. At same time, each player show his hand with 0 to 5 fingers extended. If all player show same kind of (even or odd) number, there is no winner. But ...
4
votes
3answers
269 views

Stopwatch for Alphabets

Implement Stopwatch for typing Alphabets Alphabets = "a b c d e f g h i j k l m n o p q r s t u v w x y z". Note The program should run infinitely and should stop only when Esc button is pressed. ...
-2
votes
1answer
118 views

Solitaire no-win states [duplicate]

NOTE: SIMILIAR TO Solitaire Dreams - Creating a winnable solitaire starting hand Find a minimum of 5 deck orders where if the cards were dealt out would create a game of Klondike Solitaire where ...
13
votes
6answers
4k views

Pong in the shortest code

The challenge is simple. Give the shortest code possible to reproduce the classic 2-player game of pong http://en.wikipedia.org/wiki/Pong . The level of graphics and functionality should be as close ...
13
votes
1answer
450 views

Solitaire Dreams - Creating a winnable solitaire starting hand

It's me. Cave Johnson. It's May 21st. You are working at Aperture Science, finest company on Earth, and tomorrow we're releasing Version 3.0 of our flagship windowing system (or WindowS): CavOS. ...
6
votes
10answers
567 views

Non-transitive dice game

Those of you who like Numberphile would be familiar with Dr. James Grime, who described a non-transitive dice game on his channel. The game consists of three 6-faced dice: Die 1: 3,3,3,3,3,6 Die 2: ...
14
votes
5answers
666 views

Score a game of Bowling

Your task is to sum up and output one player's score in a game of 10-pin bowling after up to 21 rolls. The rolls are represented as space separated integers on a single line of input. Each integer ...
7
votes
6answers
612 views

Score a game of Yahtzee

For each of the 13 rows of a Yahtzee scoresheet you are given (from stdin) a space separated list of 5 numbers (dice). Your task is to calculate the score for each line and output the Grand Total of ...
7
votes
4answers
2k views

Recreate the classic snake Game

The challenge is to create the classic Snake game using as few bytes as possible. Here are the requirements: The game must be implemented in a typical 2-dimensional layout. The snake should be able ...
6
votes
3answers
662 views

Build a Simple Roguelike

This challenge is based on one proposed on the usenet group rec.games.roguelike.development a few years ago. I can't find the original newsgroup post, but you can have a look a the Github repo of ...
11
votes
3answers
1k views

Score a game of Go

Scoring a Go game is a task that is not all too easy. In the past there have been several debates about how to design rules to cover all the strange corner cases that may occur. Luckily, in this task ...
17
votes
9answers
1k views

Name the poker hand

Name the poker hand Given five cards, output the name of the poker hand, which will be one of: High card One pair Two pair Three of a kind Straight Flush Full house Four of a kind Straight flush ...
10
votes
2answers
724 views

Play a perfect game of Mu Torere

Background Mu Torere is a game that is one of only two known to be played by the Maori people of New Zealand before European influence. This makes it a very unique game in that it has an "objective ...
35
votes
6answers
3k views

Create a User-Profile Mini-Game

Yesterday, I stumbled on a very clever thing. Yes, that's a working implementation of Tic-Tac-Toe on a user profile page, from @minitech. Of course, the moment I saw it, I had to reverse engineer ...
10
votes
0answers
767 views

Minimal Sudoku Generator [closed]

Ask questions if you need to, I'll elaborate on anything that needs clarified. My challenge is to unsolve a sudoku to a minimal state. Basically take a supplied, solved, sudoku board and unsolve it ...
10
votes
4answers
2k views

Best Scoring Boggle Board

I was interested in seeing the answers to this (now defunct) question, but it has never been corrected/improved. Given a set of 6-sided Boggle dice (configuration stolen from this question), ...
19
votes
5answers
1k views

Score a Cribbage Hand

This challenge is to score a Cribbage hand. If you don't play Cribbage, you've got some learning to do. We play with a standard poker deck, and a hand consists of four cards plus the "up card". ...
5
votes
1answer
1k views

Sudoku board generator

A program that randomly generates a Sudoku game board with varying degrees of difficulty (however you decide to measure difficulty). Sudoku requires that there is only one solution, so your program ...
17
votes
6answers
2k views

Recreate a 'Snake' game in a console/terminal

Games are fun this codegolf here was so fun I had to make a version for other classic games similar in complexity. Shortest Way of creating a basic Space Invaders Game in Python This time, however, ...
2
votes
1answer
1k views

Shortest Way of creating a basic Space Invaders Game in Python

Hello all code golfers: Your challenge is to create a basic version of Space Invaders in Python Rules Program must be not written in Py3K All levels must be randomly generated There must be a HUD ...
6
votes
0answers
447 views

Unique Sudoku Finder

Challenge: Given a Sudoku board on standard input, find the minimum number of numbers added to make the board unique. Specifics/Rules: The input is formatted as follows (all whitespace is ...
10
votes
2answers
623 views

A BlackJack KOTH contest

BlackJack As I had a blast working on the original KOTH challenge, I wanted to come up with another one. For me, the fun of these AI challenges is in refining a comparatively simple bot ...
3
votes
4answers
511 views

Bingo card generator

A Bingo card is five columns of five squares each, with the middle square designated "FREE". Numbers cannot duplicate. The five columns are populated with the following range of numbers: B:1-15 ...
2
votes
0answers
208 views

Console Role Playing Game [closed]

Below are a basic set of requirements. The following commands (for an interface to the game): attack <target>, <move> goto <place> buy <item> enum < targets, ...
12
votes
9answers
2k views

Hangman wordgame golf

Inspired by reddit. Write a program which plays Hangman. The program chooses a random word from a list of N words, where N > 2. The word list can be provided to the program in any way you choose. ...
10
votes
13answers
1k views

Guess the number.

Description Create a fully working "Guess the number" game. The game is played by two players as follows: player one chooses a number (A) between 1 and N player two tries to guess A choosing a ...