public String getOnePair()
    {
        StringBuilder stt = new StringBuilder();

        //search for 1 pair.
        //if found, return the pair and the highest kickers

        if (cards[0].getRank() == cards[1].getRank()) {
            stt.append(Character.toString(cards[0].getCharCard()))
                .append(cards[2].getCharCard())
                .append(cards[3].getCharCard())
                .append(cards[4].getCharCard());

            return stt.toString();
        }
        
        if (cards[1].getCharCard() == cards[2].getCharCard()) {
            stt.append(Character.toString(cards[1].getCharCard()))
                .append(cards[0].getCharCard())
                .append(cards[3].getCharCard())
                .append(cards[4].getCharCard());

            return stt.toString();
        }
        
        if (cards[2].getRank() == cards[3].getRank()) {
            stt.append(Character.toString(cards[2].getCharCard()))
                .append(cards[0].getCharCard())
                .append(cards[1].getCharCard())
                .append(cards[4].getCharCard());

            return stt.toString();
        }
        
        if (cards[3].getRank() == cards[4].getRank()) {
            stt.append(Character.toString(cards[3].getCharCard()))
                .append(cards[0].getCharCard())
                .append(cards[1].getCharCard())
                .append(cards[2].getCharCard());

            return stt.toString();
        }
        
        if (cards[4].getRank() == cards[5].getRank()) {
            stt.append(Character.toString(cards[4].getCharCard()))
                .append(cards[0].getCharCard())
                .append(cards[1].getCharCard())
                .append(cards[2].getCharCard());

            return stt.toString();
        }
        
        if (cards[5].getRank() == cards[6].getRank()) {
            stt.append(Character.toString(cards[5].getCharCard()))
                .append(cards[0].getCharCard())
                .append(cards[1].getCharCard())
                .append(cards[2].getCharCard());

            return stt.toString();
        }

        return "0";
    }