private int scoreHand( List< Card > hand ){
        if( isRoyalFlush( hand ) )
            return Integer.MAX_VALUE;
        
        int val,highCard = getHighestValue( hand );
        
        val = getBestStraightFlushValue( hand );
        if( val != -1 )
            return 100000 + 15*val + highCard;
        
        val = getQuadValue( hand );
        if( val != -1 )
            return 90000 + 15*val + highCard;
        
        val = getFullHouseValue( hand );
        if( val != -1 )
            return 80000 + 15*val + highCard;
        
        if( isFlush( hand ) )
            return 70000 + highCard;
        
        val = getBestStraightValue( hand );
        if( val != -1 )
            return 60000 + 15*val + highCard;
        
        val = getTripleValue( hand );
        if( val != -1 )
            return 50000 + 15*val + highCard;
        
        val = getBestDoublePairValue( hand );
        if( val != -1 )
            return 40000 + 15*val + highCard;
        
        val = getBestPairValue( hand );
        if( val != -1 )
            return 30000 + 15*val + highCard;
        
        return highCard;
    }