GithubHelp home page GithubHelp logo

tempbottle / qipai Goto Github PK

View Code? Open in Web Editor NEW

This project forked from yuanfengyun/q_algorithm

0.0 3.0 0.0 12.01 MB

棋牌的胡牌算法,包括麻将、跑胡子、扑克。实现lua、c++、c#、golang、js、java、python版本。(Mahjong algorithm)

C# 7.61% C++ 40.27% Makefile 0.34% Shell 0.03% Go 3.51% Java 6.22% JavaScript 4.11% Lua 27.50% Batchfile 0.05% Python 0.94% C 9.43%

qipai's Introduction

qipai

棋牌的胡牌算法,特殊牌型判断算法

1、跑胡子算法

实现:

有C++版(基于递归,回溯)。

lua版(基于查表)。

2、高效的麻将胡牌算法,能处理任意张赖子:

速度:1S左右处理100万次每次四个赖子的麻将判胡;5秒处理1亿次八个赖子判胡(golang虚拟机上实测)。

实现:

  基于花色切分,然后查表。
  
  有多种语言版本:lua、c++、c#、golang、js、java、python。

3、无敌的拆牌判胡算法,不占用额外内存,速度、简洁度超过查表法。支持任意赖子数量。

4、特殊牌型判断:一条龙、掐张、七对、碰碰胡、十三幺、单吊、大吊车、清一色、缺门、门清。

tips: 深圳、广州范围提供上门讲解、替换现有算法服务,QQ:273461474。觉得好的话,别忘了点上一个星 ^_^

已使用的项目或公司(不完全统计):

易县麻将: https://fir.im/yizhouqipai (8个赖子)

乾娱科技: http://www.qygames.net/

陌陌: https://www.immomo.com/

探娱互动: http://www.tanyu.mobi/

雪狼网络: http://www.23xl.com/

深圳大麦网络科技:http://www.59iwan.cn

深圳智熊网络: http://www.bearuc.com/

qipai's People

Contributors

yuanfengyun avatar

Watchers

James Cloos avatar tempbottle avatar  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.