Giter Club home page Giter Club logo

flood-it's Introduction

Flood It

In Flood It, you are given a grid of squares of various colours. Your objective is to fill the entire grid with the same colour. To do this, you are allowed to change the colour of the top left square and all other squares connected to it every turn. Two squares are connected if they are adjacent and of the same colour. If you choose the right colours, you will eventually fill the entire grid with the same colour.

In this implementation, the computer will find a solution using a greedy algorithm, choosing the colour that will connect the most squares. This will not result in the optimal solution since this problem is NP-Hard. The player's goal is to find a better solution than the computer (or a solution that's just as good), which is possible because the computer will most likely not find the optimal solution.

The game is written in jQuery/Javascript and makes use of Twitter bootstrap to make it look nice.

Enjoy!

flood-it's People

Contributors

ddycai avatar frigidrain avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

flood-it's Issues

Add License Information

Hello Duncan,

Thanks for sharing the source code of Flood It. I guess, you shared the source code of this software so that anyone can run, copy, distribute, study, change and improve the software. In other words, you want your software to respect the users' freedom, what any free software does.

Unfortunately, you haven't added any license information to the source code of this program. As long as, there is NO LICENSE with the source code, we cannot consider a software as a free software, even if you have no problem to let anyone have the freedom to run, copy, distribute, study, change and improve the software.

I wish, you want your software to respect the freedom of its users, and have no problem to license it under a free software license, for example, the GNU Affero General Public License.

Thanks.

Nave Nobel

Dialog Box bug

Says 'You've bested computer' when you ask computer to solve it.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.