cokcjswo   6년 전

출력 부분 설명은 다음과 같습니다


Write to the standard output a shortest sequence of moves (numbers), which returns all the dials to 12 o'clock. In case there are many solutions, only one is required.

해석하면, 단순히 가장 짧은 sequence를 출력하라고 적혀있는데, 실상은 sequence가 increasing order인 경우만 답으로 받아들이고 있습니다.

주어진 테스트케이스를 예로들면 4 5 8 9가 답이면, 5 8 4 9도 답이고, 9 4 8 5도 답인데 (순서가 상관 없습니다), 4 5 8 9 즉, increasing order인 경우만 답으로 받아들입니다.

위의 문장을 

Write to the standard output a shortest sequence of moves (numbers) in increasing order, which returns all the dials to 12 o'clock. In case there are many solutions, only one is required.

로 바꾸면 문제가 해결될 것 같습니다.

startlink   6년 전

조건 추가했습니다.

댓글을 작성하려면 로그인해야 합니다.