IMPLICIT NONE integer::N,K read*,N,K print"(i0)",merge(K-1,-1,N>=K) end