{"action":"created","comment":{"url":"https://api.github.com/repos/code-squad/java-ladder/pulls/comments/175221572","pull_request_review_id":104726277,"id":175221572,"diff_hunk":"@@ -7,32 +7,32 @@ public static boolean randomBoolean() {\n         return (Math.random() < 0.5) ? false : true;\n     }\n \n-    public static int findLadderResult(int col, Ladder ladder){\n-        int row = 0;\n-        String direction = \"down\"; // initialize\n-        int maxRightIndex = ladder.getLadderForm().get(1).getPoints().size();\n-        while (row < ladder.getLadderForm().size()) {\n-            switch (direction) {\n-                case \"down\":\n-                    if (col == 0 && ladder.getLadderValue(row, col)) { col++; direction = \"right\"; break; }\n-                    if (col == 0 && !ladder.getLadderValue(row, col)) { row++; direction = \"down\"; break; }\n-                    if (col == maxRightIndex && ladder.getLadderValue(row, col - 1)) { col--; direction = \"left\"; break; }\n-                    if (col == maxRightIndex && !ladder.getLadderValue(row, col - 1)) { row++; direction = \"down\"; break; }\n-                    if (ladder.getLadderValue(row, col - 1)) { col--; direction = \"left\"; break; }\n-                    if (ladder.getLadderValue(row, col)) { col++; direction = \"right\"; break; }\n-                    if (ladder.getLadderValue(row, col - 1) && ladder.getLadderValue(row, col)) { row++; direction = \"down\"; break; }\n-\n-                case \"left\":\n-                    if (col == 0) { row++; direction = \"down\"; break; }\n-                    if (ladder.getLadderValue(row, col - 1)) { col--; direction = \"left\"; break; }\n-                    if (!ladder.getLadderValue(row, col - 1)) { row++; direction = \"down\"; break; }\n-\n-                case \"right\":\n-                    if (col == maxRightIndex) { row++; direction = \"down\"; break; }\n-                    if (ladder.getLadderValue(row, col)) { col++; direction = \"right\"; break; }\n-                    if (!ladder.getLadderValue(row, col)) { row++; direction = \"down\"; break; }\n-            }\n-        }\n-        return col;\n-    }\n+//    public static int findLadderResult(int col, Ladder ladder){\n+//        int row = 0;\n+//        String direction = \"down\"; // initialize\n+//        int maxRightIndex = ladder.getLadderForm().get(1).getPoints().size();\n+//        while (row < ladder.getLadderForm().size()) {\n+//            switch (direction) {\n+//                case \"down\":\n+//                    if (col == 0 && ladder.getLadderValue(row, col)) { col++; direction = \"right\"; break; }\n+//                    if (col == 0 && !ladder.getLadderValue(row, col)) { row++; direction = \"down\"; break; }\n+//                    if (col == maxRightIndex && ladder.getLadderValue(row, col - 1)) { col--; direction = \"left\"; break; }\n+//                    if (col == maxRightIndex && !ladder.getLadderValue(row, col - 1)) { row++; direction = \"down\"; break; }\n+//                    if (ladder.getLadderValue(row, col - 1)) { col--; direction = \"left\"; break; }\n+//                    if (ladder.getLadderValue(row, col)) { col++; direction = \"right\"; break; }\n+//                    if (ladder.getLadderValue(row, col - 1) && ladder.getLadderValue(row, col)) { row++; direction = \"down\"; break; }\n+//\n+//                case \"left\":\n+//                    if (col == 0) { row++; direction = \"down\"; break; }\n+//                    if (ladder.getLadderValue(row, col - 1)) { col--; direction = \"left\"; break; }\n+//                    if (!ladder.getLadderValue(row, col - 1)) { row++; direction = \"down\"; break; }\n+//\n+//                case \"right\":\n+//                    if (col == maxRightIndex) { row++; direction = \"down\"; break; }\n+//                    if (ladder.getLadderValue(row, col)) { col++; direction = \"right\"; break; }\n+//                    if (!ladder.getLadderValue(row, col)) { row++; direction = \"down\"; break; }\n+//            }\n+//        }\n+//        return col;\n+//    }","path":"src/main/java/codesquad/ladder/controller/LadderUtils.java","position":37,"original_position":59,"commit_id":"5a4302f9a345305f7d70c11103ef38bfa763d3ce","original_commit_id":"5a4302f9a345305f7d70c11103ef38bfa763d3ce","user":{"login":"javajigi","id":520500,"avatar_url":"https://avatars2.githubusercontent.com/u/520500?v=4","gravatar_id":"","url":"https://api.github.com/users/javajigi","html_url":"https://github.com/javajigi","followers_url":"https://api.github.com/users/javajigi/followers","following_url":"https://api.github.com/users/javajigi/following{/other_user}","gists_url":"https://api.github.com/users/javajigi/gists{/gist_id}","starred_url":"https://api.github.com/users/javajigi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/javajigi/subscriptions","organizations_url":"https://api.github.com/users/javajigi/orgs","repos_url":"https://api.github.com/users/javajigi/repos","events_url":"https://api.github.com/users/javajigi/events{/privacy}","received_events_url":"https://api.github.com/users/javajigi/received_events","type":"User","site_admin":false},"body":"우리에게는 git이 있다.\r\n사용하지 않는 코드는 그냥 제거.","created_at":"2018-03-16T21:44:46Z","updated_at":"2018-03-16T21:47:58Z","html_url":"https://github.com/code-squad/java-ladder/pull/39#discussion_r175221572","pull_request_url":"https://api.github.com/repos/code-squad/java-ladder/pulls/39","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/code-squad/java-ladder/pulls/comments/175221572"},"html":{"href":"https://github.com/code-squad/java-ladder/pull/39#discussion_r175221572"},"pull_request":{"href":"https://api.github.com/repos/code-squad/java-ladder/pulls/39"}}},"pull_request":{"url":"https://api.github.com/repos/code-squad/java-ladder/pulls/39","id":175451515,"html_url":"https://github.com/code-squad/java-ladder/pull/39","diff_url":"https://github.com/code-squad/java-ladder/pull/39.diff","patch_url":"https://github.com/code-squad/java-ladder/pull/39.patch","issue_url":"https://api.github.com/repos/code-squad/java-ladder/issues/39","number":39,"state":"open","locked":false,"title":"Step5","user":{"login":"LarryJung","id":36081783,"avatar_url":"https://avatars2.githubusercontent.com/u/36081783?v=4","gravatar_id":"","url":"https://api.github.com/users/LarryJung","html_url":"https://github.com/LarryJung","followers_url":"https://api.github.com/users/LarryJung/followers","following_url":"https://api.github.com/users/LarryJung/following{/other_user}","gists_url":"https://api.github.com/users/LarryJung/gists{/gist_id}","starred_url":"https://api.github.com/users/LarryJung/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LarryJung/subscriptions","organizations_url":"https://api.github.com/users/LarryJung/orgs","repos_url":"https://api.github.com/users/LarryJung/repos","events_url":"https://api.github.com/users/LarryJung/events{/privacy}","received_events_url":"https://api.github.com/users/LarryJung/received_events","type":"User","site_admin":false},"body":"step5 구현해 봤습니다.\r\n로직을 구현하는데 while-if 가 중복되는 상황에서 depth를 줄이지 못했습니다ㅠ\r\n처음 생각은 (x, y, direction)을 가지는 tracker객체를 추가하여 구현하는 것을 생각하였으나,\r\ndepth를 줄이는 것과 tracker객체의 상태를 변화시켜 값을 얻어오는 로직에 어려움이 생겨서 tracker클래스를 지우고, 먼저 기능을 구현했습니다.","created_at":"2018-03-16T06:36:44Z","updated_at":"2018-03-16T21:47:58Z","closed_at":null,"merged_at":null,"merge_commit_sha":"5db887507f9d01b2d2eb183388bc48177660d8e3","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/code-squad/java-ladder/pulls/39/commits","review_comments_url":"https://api.github.com/repos/code-squad/java-ladder/pulls/39/comments","review_comment_url":"https://api.github.com/repos/code-squad/java-ladder/pulls/comments{/number}","comments_url":"https://api.github.com/repos/code-squad/java-ladder/issues/39/comments","statuses_url":"https://api.github.com/repos/code-squad/java-ladder/statuses/5a4302f9a345305f7d70c11103ef38bfa763d3ce","head":{"label":"LarryJung:step5","ref":"step5","sha":"5a4302f9a345305f7d70c11103ef38bfa763d3ce","user":{"login":"LarryJung","id":36081783,"avatar_url":"https://avatars2.githubusercontent.com/u/36081783?v=4","gravatar_id":"","url":"https://api.github.com/users/LarryJung","html_url":"https://github.com/LarryJung","followers_url":"https://api.github.com/users/LarryJung/followers","following_url":"https://api.github.com/users/LarryJung/following{/other_user}","gists_url":"https://api.github.com/users/LarryJung/gists{/gist_id}","starred_url":"https://api.github.com/users/LarryJung/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LarryJung/subscriptions","organizations_url":"https://api.github.com/users/LarryJung/orgs","repos_url":"https://api.github.com/users/LarryJung/repos","events_url":"https://api.github.com/users/LarryJung/events{/privacy}","received_events_url":"https://api.github.com/users/LarryJung/received_events","type":"User","site_admin":false},"repo":{"id":124481271,"name":"java-ladder","full_name":"LarryJung/java-ladder","owner":{"login":"LarryJung","id":36081783,"avatar_url":"https://avatars2.githubusercontent.com/u/36081783?v=4","gravatar_id":"","url":"https://api.github.com/users/LarryJung","html_url":"https://github.com/LarryJung","followers_url":"https://api.github.com/users/LarryJung/followers","following_url":"https://api.github.com/users/LarryJung/following{/other_user}","gists_url":"https://api.github.com/users/LarryJung/gists{/gist_id}","starred_url":"https://api.github.com/users/LarryJung/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LarryJung/subscriptions","organizations_url":"https://api.github.com/users/LarryJung/orgs","repos_url":"https://api.github.com/users/LarryJung/repos","events_url":"https://api.github.com/users/LarryJung/events{/privacy}","received_events_url":"https://api.github.com/users/LarryJung/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/LarryJung/java-ladder","description":"사다리 게임을 관리하는 저장소","fork":true,"url":"https://api.github.com/repos/LarryJung/java-ladder","forks_url":"https://api.github.com/repos/LarryJung/java-ladder/forks","keys_url":"https://api.github.com/repos/LarryJung/java-ladder/keys{/key_id}","collaborators_url":"https://api.github.com/repos/LarryJung/java-ladder/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/LarryJung/java-ladder/teams","hooks_url":"https://api.github.com/repos/LarryJung/java-ladder/hooks","issue_events_url":"https://api.github.com/repos/LarryJung/java-ladder/issues/events{/number}","events_url":"https://api.github.com/repos/LarryJung/java-ladder/events","assignees_url":"https://api.github.com/repos/LarryJung/java-ladder/assignees{/user}","branches_url":"https://api.github.com/repos/LarryJung/java-ladder/branches{/branch}","tags_url":"https://api.github.com/repos/LarryJung/java-ladder/tags","blobs_url":"https://api.github.com/repos/LarryJung/java-ladder/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/LarryJung/java-ladder/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/LarryJung/java-ladder/git/refs{/sha}","trees_url":"https://api.github.com/repos/LarryJung/java-ladder/git/trees{/sha}","statuses_url":"https://api.github.com/repos/LarryJung/java-ladder/statuses/{sha}","languages_url":"https://api.github.com/repos/LarryJung/java-ladder/languages","stargazers_url":"https://api.github.com/repos/LarryJung/java-ladder/stargazers","contributors_url":"https://api.github.com/repos/LarryJung/java-ladder/contributors","subscribers_url":"https://api.github.com/repos/LarryJung/java-ladder/subscribers","subscription_url":"https://api.github.com/repos/LarryJung/java-ladder/subscription","commits_url":"https://api.github.com/repos/LarryJung/java-ladder/commits{/sha}","git_commits_url":"https://api.github.com/repos/LarryJung/java-ladder/git/commits{/sha}","comments_url":"https://api.github.com/repos/LarryJung/java-ladder/comments{/number}","issue_comment_url":"https://api.github.com/repos/LarryJung/java-ladder/issues/comments{/number}","contents_url":"https://api.github.com/repos/LarryJung/java-ladder/contents/{+path}","compare_url":"https://api.github.com/repos/LarryJung/java-ladder/compare/{base}...{head}","merges_url":"https://api.github.com/repos/LarryJung/java-ladder/merges","archive_url":"https://api.github.com/repos/LarryJung/java-ladder/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/LarryJung/java-ladder/downloads","issues_url":"https://api.github.com/repos/LarryJung/java-ladder/issues{/number}","pulls_url":"https://api.github.com/repos/LarryJung/java-ladder/pulls{/number}","milestones_url":"https://api.github.com/repos/LarryJung/java-ladder/milestones{/number}","notifications_url":"https://api.github.com/repos/LarryJung/java-ladder/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/LarryJung/java-ladder/labels{/name}","releases_url":"https://api.github.com/repos/LarryJung/java-ladder/releases{/id}","deployments_url":"https://api.github.com/repos/LarryJung/java-ladder/deployments","created_at":"2018-03-09T03:17:22Z","updated_at":"2018-03-09T03:17:24Z","pushed_at":"2018-03-16T09:45:02Z","git_url":"git://github.com/LarryJung/java-ladder.git","ssh_url":"git@github.com:LarryJung/java-ladder.git","clone_url":"https://github.com/LarryJung/java-ladder.git","svn_url":"https://github.com/LarryJung/java-ladder","homepage":null,"size":154,"stargazers_count":0,"watchers_count":0,"language":"Shell","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"code-squad:larryjung","ref":"larryjung","sha":"3540306d7ae4167ddde76e53d1146156e480b3d3","user":{"login":"code-squad","id":22832280,"avatar_url":"https://avatars2.githubusercontent.com/u/22832280?v=4","gravatar_id":"","url":"https://api.github.com/users/code-squad","html_url":"https://github.com/code-squad","followers_url":"https://api.github.com/users/code-squad/followers","following_url":"https://api.github.com/users/code-squad/following{/other_user}","gists_url":"https://api.github.com/users/code-squad/gists{/gist_id}","starred_url":"https://api.github.com/users/code-squad/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/code-squad/subscriptions","organizations_url":"https://api.github.com/users/code-squad/orgs","repos_url":"https://api.github.com/users/code-squad/repos","events_url":"https://api.github.com/users/code-squad/events{/privacy}","received_events_url":"https://api.github.com/users/code-squad/received_events","type":"Organization","site_admin":false},"repo":{"id":116236679,"name":"java-ladder","full_name":"code-squad/java-ladder","owner":{"login":"code-squad","id":22832280,"avatar_url":"https://avatars2.githubusercontent.com/u/22832280?v=4","gravatar_id":"","url":"https://api.github.com/users/code-squad","html_url":"https://github.com/code-squad","followers_url":"https://api.github.com/users/code-squad/followers","following_url":"https://api.github.com/users/code-squad/following{/other_user}","gists_url":"https://api.github.com/users/code-squad/gists{/gist_id}","starred_url":"https://api.github.com/users/code-squad/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/code-squad/subscriptions","organizations_url":"https://api.github.com/users/code-squad/orgs","repos_url":"https://api.github.com/users/code-squad/repos","events_url":"https://api.github.com/users/code-squad/events{/privacy}","received_events_url":"https://api.github.com/users/code-squad/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/code-squad/java-ladder","description":"사다리 게임을 관리하는 저장소","fork":false,"url":"https://api.github.com/repos/code-squad/java-ladder","forks_url":"https://api.github.com/repos/code-squad/java-ladder/forks","keys_url":"https://api.github.com/repos/code-squad/java-ladder/keys{/key_id}","collaborators_url":"https://api.github.com/repos/code-squad/java-ladder/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/code-squad/java-ladder/teams","hooks_url":"https://api.github.com/repos/code-squad/java-ladder/hooks","issue_events_url":"https://api.github.com/repos/code-squad/java-ladder/issues/events{/number}","events_url":"https://api.github.com/repos/code-squad/java-ladder/events","assignees_url":"https://api.github.com/repos/code-squad/java-ladder/assignees{/user}","branches_url":"https://api.github.com/repos/code-squad/java-ladder/branches{/branch}","tags_url":"https://api.github.com/repos/code-squad/java-ladder/tags","blobs_url":"https://api.github.com/repos/code-squad/java-ladder/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/code-squad/java-ladder/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/code-squad/java-ladder/git/refs{/sha}","trees_url":"https://api.github.com/repos/code-squad/java-ladder/git/trees{/sha}","statuses_url":"https://api.github.com/repos/code-squad/java-ladder/statuses/{sha}","languages_url":"https://api.github.com/repos/code-squad/java-ladder/languages","stargazers_url":"https://api.github.com/repos/code-squad/java-ladder/stargazers","contributors_url":"https://api.github.com/repos/code-squad/java-ladder/contributors","subscribers_url":"https://api.github.com/repos/code-squad/java-ladder/subscribers","subscription_url":"https://api.github.com/repos/code-squad/java-ladder/subscription","commits_url":"https://api.github.com/repos/code-squad/java-ladder/commits{/sha}","git_commits_url":"https://api.github.com/repos/code-squad/java-ladder/git/commits{/sha}","comments_url":"https://api.github.com/repos/code-squad/java-ladder/comments{/number}","issue_comment_url":"https://api.github.com/repos/code-squad/java-ladder/issues/comments{/number}","contents_url":"https://api.github.com/repos/code-squad/java-ladder/contents/{+path}","compare_url":"https://api.github.com/repos/code-squad/java-ladder/compare/{base}...{head}","merges_url":"https://api.github.com/repos/code-squad/java-ladder/merges","archive_url":"https://api.github.com/repos/code-squad/java-ladder/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/code-squad/java-ladder/downloads","issues_url":"https://api.github.com/repos/code-squad/java-ladder/issues{/number}","pulls_url":"https://api.github.com/repos/code-squad/java-ladder/pulls{/number}","milestones_url":"https://api.github.com/repos/code-squad/java-ladder/milestones{/number}","notifications_url":"https://api.github.com/repos/code-squad/java-ladder/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/code-squad/java-ladder/labels{/name}","releases_url":"https://api.github.com/repos/code-squad/java-ladder/releases{/id}","deployments_url":"https://api.github.com/repos/code-squad/java-ladder/deployments","created_at":"2018-01-04T08:46:50Z","updated_at":"2018-03-13T00:59:23Z","pushed_at":"2018-03-16T13:26:29Z","git_url":"git://github.com/code-squad/java-ladder.git","ssh_url":"git@github.com:code-squad/java-ladder.git","clone_url":"https://github.com/code-squad/java-ladder.git","svn_url":"https://github.com/code-squad/java-ladder","homepage":null,"size":178,"stargazers_count":0,"watchers_count":0,"language":"Shell","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":9,"mirror_url":null,"archived":false,"open_issues_count":8,"license":null,"forks":9,"open_issues":8,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/code-squad/java-ladder/pulls/39"},"html":{"href":"https://github.com/code-squad/java-ladder/pull/39"},"issue":{"href":"https://api.github.com/repos/code-squad/java-ladder/issues/39"},"comments":{"href":"https://api.github.com/repos/code-squad/java-ladder/issues/39/comments"},"review_comments":{"href":"https://api.github.com/repos/code-squad/java-ladder/pulls/39/comments"},"review_comment":{"href":"https://api.github.com/repos/code-squad/java-ladder/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/code-squad/java-ladder/pulls/39/commits"},"statuses":{"href":"https://api.github.com/repos/code-squad/java-ladder/statuses/5a4302f9a345305f7d70c11103ef38bfa763d3ce"}},"author_association":"NONE"}}
{"actor":{"display_login":"javajigi"}}