get_number(Number) :-
    get_string(String),
    number_string(Number, String).

get_string(String) :-
    current_input(Input),
    read_string(Input, ' \n', '', _, String).

/* memo
    string_code(1, S, C),
*/

f(A,A,B) :- A \= B.
f(A,B,A) :- A \= B.
f(B,A,A) :- A \= B.

main:-
    get_number(A),
    get_number(B),
    get_number(C),
    (f(A,B,C)) -> writeln("Yes") ; writeln("No").
