#!/usr/local/bin/perl -w
###########################################
# suite - CardSuite testing hypothesis
# 2014, Mike Schilli <m@perlmeister.com>
###########################################
use strict;
package CardHypoTest;
use base qw( HypoTest );

sub likelihood {
  my( $self, $data, $hypo ) = @_;

    # count the number or Rs in the string
  my @matches = ( $hypo =~ /($data)/g );
  return @matches / 2.0;
}

package main;
my $suite = CardHypoTest->new();

$suite->hypo_add( "RR" );
$suite->hypo_add( "BB" );
$suite->hypo_add( "RB" );

$suite->update( "R" );
$suite->print();
