Questions tagged [poker]

Questions relating to development on the subject of all variants of poker.

Questions in this category contains all aspects of development relating to poker - ie. hand evaluation, game engine, statistics, etc.

464 questions
3
votes
2 answers

Java poker hand evaluator to not working

I'm trying to figure out how to pass this but actually be working. I am afraid I'm getting false positives. public static boolean hasPair(Card[] cards) { Card[] pair= new Card[5]; for(int i=0; i<5; i++) { for(int j=i+1; j<5;…
Cferrel
  • 321
  • 2
  • 5
  • 19
3
votes
1 answer

How to find how many times the same object appears in a list and then find a property of the most appeared object

I'm making a poker hand evaluator for some programming practice which i have been submitting to codereview stack exchange. I need to be able to compare hands properly and for this I need to see the value of pairs. My Current check hand for pairs…
Steve
  • 35
  • 4
3
votes
1 answer

Poker hand - Determining a full house in F#

Having this issue of my fullHouse function = true when there's a three-of-a-kind. The function checks for a 3 of a kind and a pair but it satisfies the logic with just a three of a kind (D, Ace)(C, Ace)(S, Ace)(D, Ten)(D, 9). This isn't a full house…
anon
3
votes
3 answers

Create a deck of cards with Faces and Suits using int Arrays

I am trying to create a simple poker game Texas Hold'em style with c. At first, I tried to create a deck of cards with 2 char arrays: char *suits_str[4] = {"Spades", "Hearts", "Diamonds", "Clubs"}; char *faces_str[13] = {"2", "3", "4", "5", "6",…
Quan Bui
  • 175
  • 1
  • 13
3
votes
3 answers

preg_replace multiple instances on 1 line?

I have text like this from poker software (I have highlighted the parts I need to replace). --- FLOP --- [Jh 9h Ah] driverseati checks darrington has 15 seconds left to act darrington bets 100 InvisibleEnigma calls 100 driverseati folds …
Fred Fickleberry III
  • 2,439
  • 4
  • 34
  • 50
3
votes
2 answers

Calculating winning odds - Poker bot

I am trying to build a poker bot in java. I have written the hand evaluation class and I am about to start feeding a neural network but I face a problem. I need the winning odds of every hand for every step: preflop, flop, turn, river. My problem is…
dirac
  • 309
  • 1
  • 9
3
votes
4 answers

Check for poker straight

I have managed to create an algorithm to check the rank of a poker hand. It works 100% correctly, but it's very slow. I've been analysing the code, and the check straight function is one of the slowest parts of it. So my question is, is there a…
Patchesoft
  • 317
  • 6
  • 21
3
votes
3 answers

Get range percentage of a length string

I'm facing a problem. I'm learning c++. I took a poker context ; The goal is to get a certain hand range from a string length ; the string represents all starting hands in a poker game , in the order stronger first. string hand =…
3
votes
3 answers

All possible combinations of card/poker hands for a set of players

I am looking for an elegant(fast) python function that produces every combination from the following two arrays. cards = ["8H", "8S", "8C", "8D", "9H", "9S", "9C", "9D", "10H", "10S", "10C", "10D", "AH", "AS", "AC", "AD"] players = ["_1", "_1",…
3
votes
0 answers

Create a poker table scanner

I'm trying to build a table scanner for the software pokerstars (this is totally legal). The software looks like this: The two parts that are interesting for the software are highlighted in orange. On the left part are all off the table names, on…
edi9999
  • 19,701
  • 13
  • 88
  • 127
3
votes
4 answers

Making Multiple Decks of Cards Java

Edit: I'm getting an error while trying to add the card to my originalDecks and dealDecks. I think I have figured out how to create a single deck of cards [shown in the method Decks()], but my problem is that I have to create multiple decks of cards…
MikaelCMiller
  • 95
  • 3
  • 14
3
votes
5 answers

fast poker hand ranking

I am working on a simulation of poker and now I have to rank hands effectively: Every hand is a combination of 5 cards and is represented as an uint64_t. Every bit from 0 (Ace of Spades), 1 (Ace of Hearts) to 51 (Two of Clubs) indicates if the…
Robin des Bois
  • 355
  • 2
  • 6
  • 20
3
votes
1 answer

How to compile Boost (and link?) libraries in cygwin windows7 i686-w64-mingw32-g++ with bjam

Problem compile boost to use it in cygwin environement with jam Environement and my skills First of all thank you for reading my message and I use windows 7 pentium i3 cygwin i686-w64-mingw32-g++. I am a beginner (10 000 lines of c c++ basic code,…
user2964288
  • 83
  • 1
  • 11
3
votes
3 answers

Finding all combinations of longs with certain bits set

This is such an obscure problem that I suspect I'll have to do it at a different level in my code...but hopefully the hive mind that is Stack Overflow can help... I have a long, which if expressed as a binary string will have exactly five bits set.…
Steve McLeod
  • 51,737
  • 47
  • 128
  • 184
3
votes
2 answers

Fill poker pots

Essentially there is a table and player A raises to 100$, player B calls (accepts), player C only has 50$ so the pots are created as 100$ (between player A and B) and 150$ (between all three players because everyone chips in at 50$). How would I…
user2498443
  • 143
  • 6