|
|
back to boardWhi wrang it avresing good in it . i chack it by given procedure and all tests is good. help please var x,y:longint; begin readln(x,y); if x=y then begin writeln(x,' ',y);halt; end; if ((x mod 2= 0)and(y mod 2 = 0))or((x mod 2<>0)and(y mod 2<>0)) then begin writeln(x,' ',y);halt; end; writeln(y,' ',x); end. I see that you not check x>0 and y>0. Try negative numbers. > var x,y:longint; > begin > readln(x,y); > if x=y then > begin > writeln(x,' ',y);halt; > end; > if ((x mod 2= 0)and(y mod 2 = 0))or((x mod 2<>0)and(y mod 2<>0)) > then > begin > writeln(x,' ',y);halt; > end; > writeln(y,' ',x); > end. |
|
|