private int checkBetterFlushOrHighCard(List<Card> cards1, List<Card> cards2) {
        /* If one hand contains an ace and the other one doesn't,
         * the hand with an ace wins.
         */
        Rank hand1RankOfFirstCard = cards1.get(0).getRank();
        Rank hand2RankOfFirstCard = cards2.get(0).getRank();        
        if (hand1RankOfFirstCard == Rank.ACE && hand2RankOfFirstCard != Rank.ACE) {
            return -1;
        }
        if (hand1RankOfFirstCard != Rank.ACE && hand2RankOfFirstCard == Rank.ACE) {
            return 1;
        }        
        // Checking which hand has the higher cards.
        for (int i = cards1.size() - 1; i >= 0; i--) {
            int hand1CardValue = cards1.get(i).getRank().getValue();
            int hand2CardValue = cards2.get(i).getRank().getValue();
            int difference = hand2CardValue - hand1CardValue;
            if (difference != 0) {
                return difference;
            }
        }
        return 0;
    }