Code Monkey home page Code Monkey logo

chess's Introduction

CHESS

  • Can play all basic moves. Special moves like en passant, castling and pawn promotion are yet to be done.

About the implementation

  • The program is implemented using mini-max algorithm with alpha beta pruning on top of it
  • Initially a shallow search upto a depth of 3 without alpha beta pruning is done (each ply is considered as a level in search tree, so here depth 3 means black move - white move - black move), and the order of moves is changed based on the result obtained form the shallow search.
  • Now with these obtained possible next moves, a search upto a depth of 5 is done, this time with alpha beta pruning.
  • A move is considered worthy by the computer only if it lead to capture of a opponent piece or checkmate of the opponent.
  • The pieces have the following values. (Inside the code computer is referred as black and human is referred as white)
  •  White and Black pawn -> 1.
     White rook -> 5 and Black rook -> 6.
     White bishop -> 4 and Black bishop -> 5.
     White knight -> 3 and Black knight -> 4.
     White queen -> 12 and Black queen -> 13.
     White and Black king -> 1000.
    

chess's People

Contributors

harishb97 avatar

Stargazers

 avatar

Watchers

 avatar

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.