D18566: Support for solving Golf using bh-solver.

Shlomi Fish noreply at phabricator.kde.org
Tue Feb 5 12:58:56 GMT 2019


shlomif added a comment.


  Hi!
  
  I found out that kpat has a command line range solving mode. Here are the results of the first 5,000 deals:
  
    Old		New		Count
    ---		---		-----
    lost		lost		2291
    lost		unknown		462
    lost		won		930
    unknown		lost		9
    unknown		unknown		56
    unknown		won		38
    won		unknown		13
    won		won		1201
  
  They were generated using:
  
    #! /bin/bash
    #
    # analyze.bash
    # Copyright (C) 2019 Shlomi Fish <shlomif at cpan.org>
    #
    # Distributed under terms of the MIT license.
    #
    
    
    filt2()
    {
        grep -E '^[1-9]' | head -5000
    }
    filt()
    {
        filt2 | perl -lanE 'say $F[1]'
    }
    echo $'Old\t\tNew\t\tCount'
    echo $'Old\t\tNew\t\tCount' | perl -lpE 's/\w/-/g'
    paste <(< old-golfs.txt filt) <(< new-golfs.txt filt) | sort | uniq -c | perl -lanE 'say "$F[1]\t\t$F[2]\t\t$F[0]"'
  
  The new solver (bh-solver) solves more deals including ones that were reported as impossible. It seems to be slower in bulk mode though, but it is fast enough for solving a single deal.

REPOSITORY
  R410 KPatience

REVISION DETAIL
  https://phabricator.kde.org/D18566

To: shlomif, #kde_games
Cc: aacid, kde-games-devel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-games-devel/attachments/20190205/be7a74d0/attachment.html>


More information about the kde-games-devel mailing list