Write a program that reads four integers and determines if two of them are equal and the remaining ones are different from any other.
Four integers in one line.
If two integers in the input are equal to each other and the other
two are different from any other one then print
YES. Otherwise, print
NO.
You cannot use massive storage data structures, such as
string or
vector.
Input
15 -30 2 15
Output
YES
Input
-333 22 -333 -333
Output
NO
Input
0 0 0 0
Output
NO
Input
1 2 4 8
Output
NO
Input
1 -1 1 -1
Output
NO