-
지문을 멋대로 해석해버린 예시실수모음 2023. 9. 22. 15:55
일반화의 오류
순서쌍의 위치에 의미가 있을것이라고 생각
순서쌍에 대한 배경지식이 작용하여 순서쌍의 각 위치에도 의미(순서쌍의 첫 번째 오는 팀이 상대적인 순위가 더 높아졌다고 착각)가 있을것이라고 생각했다. 예시를 보고 이해하되, 그 예시가 강조하고 싶었던 것이 무었이었는지 다시 한번 상기하자.
2
1 2
1
1 2
답 : 2 1
오답 : 1 2물리적으로 한 칸씩 움직일것이라고 생각(이 또한 문제를 잘못 읽은 것이었음....)문제가 일상에서 볼 수 있는 로봇에 관한 문제였다. 그래서 3칸 이동 명령이 떨어지면 당연히 1칸씩 3번 이동할 것이라고 생각했다. 문제는 곧이곧대로 이해할 것.위와같은 문제 조건이 있으므로 로봇은 궤도를 따라 움직이는 것이 맞음.
1 40 1 1 01 1 11 4 1답 : 1오답 : (출력 없음)문제를 다 읽지 않음(특히 출력부분)
입력을 읽지 않음
입력부분에 지도 밖으로 나가는 방향의 입력이 주어지지 않는다고 명시되어있지만, 이 부분을 읽지 않아 필요없는 예외처리를 하게 됨
테스트 케이스로 주어지는데, 테스트 케이스의 개수가 주어지지 않는 경우도 있음
출력을 읽지 않음
출력부분은 정답과 직접적으로 관련된 부분이기 때문에 위와같은 사소한 부분? 빼먹으로 디버깅하는데 시간을 많이 버리게 된다!!
종류인지 개수인지?
버려도 되는지 안 되는지 여부를 멋대로 판단
자른 소세지의 일부를 버려도 되는 것으로 해석했다. 버려도 되고 아니고는 중요한 문제이므로 함부로 판단하지 않도록 하자.
위 지문에서는 예시에 이 부분이 함의되어 있다.원문에서는 "sausages which need to be distributed to M tasters"이라고 서술되어 있으므로 소세지 전체를 나눠주는 것인 것에 이견이 없어보인다.
'실수모음' 카테고리의 다른 글
dfs를 이용한 완탐시, 방문 해제 모두 하고 return true (0) 2023.10.24 또~~~~ 버 플로우(경우를 세는 경우 오버플로우 날 수 있다) (2) 2023.10.17 [c++] round(-0.3)은 -0을 출력한다. 조심할 것 (0) 2023.09.05 1차원 dp를 사용할 땐, 중복 갱신에 주의해야 함(경우에 따라 역순으로 갱신할것) (0) 2023.08.28 코딩 할 때가 아닌 것 같은데?? (0) 2023.03.03