I am making a poker game in java using eclipse, I need help with creating a code to find a PAIR for a single line of input. If the user enters: 12,11,5,2,12
then how can I identify if the input has two of the same numbers then print it as a PAIR.
So basically I've already taken a string input and then converted it into a String array with a split function to identify the numbers and then made it into a Int array.
When a user input: 12,3,4,5,12
-- it should print in the output: PAIR