{"action":"created","comment":{"url":"https://api.github.com/repos/practice271/assignments/pulls/comments/42944720","id":42944720,"diff_hunk":"@@ -0,0 +1,48 @@\n+package hw06\n+\n+import java.util.*\n+\n+public class Logic(){\n+    var arrPlay = Array(9,{i -> 0})\n+\n+    public fun availableStroke(): Boolean{\n+        return (!arrPlay.contains(0))\n+    }\n+\n+    public fun winer(): Int{\n+        if (arrPlay[0] == 1 && arrPlay[3] == 1 && arrPlay[6] == 1 ||\n+                arrPlay[0] == 1 && arrPlay[1] == 1 && arrPlay[2] == 1 ||\n+                arrPlay[0] == 1 && arrPlay[4] == 1 && arrPlay[8] == 1 ||\n+                arrPlay[2] == 1 && arrPlay[4] == 1 && arrPlay[6] == 1 ||\n+                arrPlay[1] == 1 && arrPlay[4] == 1 && arrPlay[7] == 1 ||\n+                arrPlay[2] == 1 && arrPlay[5] == 1 && arrPlay[8] == 1 ||\n+                arrPlay[3] == 1 && arrPlay[4] == 1 && arrPlay[5] == 1 ||\n+                arrPlay[6] == 1 && arrPlay[7] == 1 && arrPlay[8] == 1){\n+            return 1\n+        }\n+        if (arrPlay[0] == 2 && arrPlay[3] == 2 && arrPlay[6] == 2 ||\n+                arrPlay[0] == 2 && arrPlay[1] == 2 && arrPlay[2] == 2 ||\n+                arrPlay[0] == 2 && arrPlay[4] == 2 && arrPlay[8] == 2 ||\n+                arrPlay[2] == 2 && arrPlay[4] == 2 && arrPlay[6] == 2 ||\n+                arrPlay[1] == 2 && arrPlay[4] == 2 && arrPlay[7] == 2 ||\n+                arrPlay[2] == 2 && arrPlay[5] == 2 && arrPlay[8] == 2 ||\n+                arrPlay[3] == 2 && arrPlay[4] == 2 && arrPlay[5] == 2 ||\n+                arrPlay[6] == 2 && arrPlay[7] == 2 && arrPlay[8] == 2){\n+            return 2\n+        }","path":"src/main/kotlin/hw06/Logic.kt","position":32,"original_position":32,"commit_id":"4469dbabb4deba657a938d06204e7d4229f444aa","original_commit_id":"4469dbabb4deba657a938d06204e7d4229f444aa","user":{"login":"AwesomeLemon","id":8983709,"avatar_url":"https://avatars.githubusercontent.com/u/8983709?v=3","gravatar_id":"","url":"https://api.github.com/users/AwesomeLemon","html_url":"https://github.com/AwesomeLemon","followers_url":"https://api.github.com/users/AwesomeLemon/followers","following_url":"https://api.github.com/users/AwesomeLemon/following{/other_user}","gists_url":"https://api.github.com/users/AwesomeLemon/gists{/gist_id}","starred_url":"https://api.github.com/users/AwesomeLemon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AwesomeLemon/subscriptions","organizations_url":"https://api.github.com/users/AwesomeLemon/orgs","repos_url":"https://api.github.com/users/AwesomeLemon/repos","events_url":"https://api.github.com/users/AwesomeLemon/events{/privacy}","received_events_url":"https://api.github.com/users/AwesomeLemon/received_events","type":"User","site_admin":false},"body":"Чтобы не копипастить условия, можно было бы сделать вспомогательную функцию checkMark(mark : Int), и вызвать её 2 раза.","created_at":"2015-10-25T13:19:27Z","updated_at":"2015-10-25T13:19:27Z","html_url":"https://github.com/practice271/assignments/pull/157#discussion_r42944720","pull_request_url":"https://api.github.com/repos/practice271/assignments/pulls/157","_links":{"self":{"href":"https://api.github.com/repos/practice271/assignments/pulls/comments/42944720"},"html":{"href":"https://github.com/practice271/assignments/pull/157#discussion_r42944720"},"pull_request":{"href":"https://api.github.com/repos/practice271/assignments/pulls/157"}}},"pull_request":{"url":"https://api.github.com/repos/practice271/assignments/pulls/157","id":48669968,"html_url":"https://github.com/practice271/assignments/pull/157","diff_url":"https://github.com/practice271/assignments/pull/157.diff","patch_url":"https://github.com/practice271/assignments/pull/157.patch","issue_url":"https://api.github.com/repos/practice271/assignments/issues/157","number":157,"state":"open","locked":false,"title":"hw06","user":{"login":"AnnaAK","id":8983718,"avatar_url":"https://avatars.githubusercontent.com/u/8983718?v=3","gravatar_id":"","url":"https://api.github.com/users/AnnaAK","html_url":"https://github.com/AnnaAK","followers_url":"https://api.github.com/users/AnnaAK/followers","following_url":"https://api.github.com/users/AnnaAK/following{/other_user}","gists_url":"https://api.github.com/users/AnnaAK/gists{/gist_id}","starred_url":"https://api.github.com/users/AnnaAK/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AnnaAK/subscriptions","organizations_url":"https://api.github.com/users/AnnaAK/orgs","repos_url":"https://api.github.com/users/AnnaAK/repos","events_url":"https://api.github.com/users/AnnaAK/events{/privacy}","received_events_url":"https://api.github.com/users/AnnaAK/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-10-25T02:11:21Z","updated_at":"2015-10-25T13:19:27Z","closed_at":null,"merged_at":null,"merge_commit_sha":"1dbc18072282fd65df7a38b86f9b311610f90d86","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/practice271/assignments/pulls/157/commits","review_comments_url":"https://api.github.com/repos/practice271/assignments/pulls/157/comments","review_comment_url":"https://api.github.com/repos/practice271/assignments/pulls/comments{/number}","comments_url":"https://api.github.com/repos/practice271/assignments/issues/157/comments","statuses_url":"https://api.github.com/repos/practice271/assignments/statuses/4469dbabb4deba657a938d06204e7d4229f444aa","head":{"label":"AnnaAK:hw06","ref":"hw06","sha":"4469dbabb4deba657a938d06204e7d4229f444aa","user":{"login":"AnnaAK","id":8983718,"avatar_url":"https://avatars.githubusercontent.com/u/8983718?v=3","gravatar_id":"","url":"https://api.github.com/users/AnnaAK","html_url":"https://github.com/AnnaAK","followers_url":"https://api.github.com/users/AnnaAK/followers","following_url":"https://api.github.com/users/AnnaAK/following{/other_user}","gists_url":"https://api.github.com/users/AnnaAK/gists{/gist_id}","starred_url":"https://api.github.com/users/AnnaAK/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AnnaAK/subscriptions","organizations_url":"https://api.github.com/users/AnnaAK/orgs","repos_url":"https://api.github.com/users/AnnaAK/repos","events_url":"https://api.github.com/users/AnnaAK/events{/privacy}","received_events_url":"https://api.github.com/users/AnnaAK/received_events","type":"User","site_admin":false},"repo":{"id":43736808,"name":"assignments","full_name":"AnnaAK/assignments","owner":{"login":"AnnaAK","id":8983718,"avatar_url":"https://avatars.githubusercontent.com/u/8983718?v=3","gravatar_id":"","url":"https://api.github.com/users/AnnaAK","html_url":"https://github.com/AnnaAK","followers_url":"https://api.github.com/users/AnnaAK/followers","following_url":"https://api.github.com/users/AnnaAK/following{/other_user}","gists_url":"https://api.github.com/users/AnnaAK/gists{/gist_id}","starred_url":"https://api.github.com/users/AnnaAK/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AnnaAK/subscriptions","organizations_url":"https://api.github.com/users/AnnaAK/orgs","repos_url":"https://api.github.com/users/AnnaAK/repos","events_url":"https://api.github.com/users/AnnaAK/events{/privacy}","received_events_url":"https://api.github.com/users/AnnaAK/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/AnnaAK/assignments","description":"The repository to fork and complete assignments in it.","fork":true,"url":"https://api.github.com/repos/AnnaAK/assignments","forks_url":"https://api.github.com/repos/AnnaAK/assignments/forks","keys_url":"https://api.github.com/repos/AnnaAK/assignments/keys{/key_id}","collaborators_url":"https://api.github.com/repos/AnnaAK/assignments/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/AnnaAK/assignments/teams","hooks_url":"https://api.github.com/repos/AnnaAK/assignments/hooks","issue_events_url":"https://api.github.com/repos/AnnaAK/assignments/issues/events{/number}","events_url":"https://api.github.com/repos/AnnaAK/assignments/events","assignees_url":"https://api.github.com/repos/AnnaAK/assignments/assignees{/user}","branches_url":"https://api.github.com/repos/AnnaAK/assignments/branches{/branch}","tags_url":"https://api.github.com/repos/AnnaAK/assignments/tags","blobs_url":"https://api.github.com/repos/AnnaAK/assignments/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/AnnaAK/assignments/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/AnnaAK/assignments/git/refs{/sha}","trees_url":"https://api.github.com/repos/AnnaAK/assignments/git/trees{/sha}","statuses_url":"https://api.github.com/repos/AnnaAK/assignments/statuses/{sha}","languages_url":"https://api.github.com/repos/AnnaAK/assignments/languages","stargazers_url":"https://api.github.com/repos/AnnaAK/assignments/stargazers","contributors_url":"https://api.github.com/repos/AnnaAK/assignments/contributors","subscribers_url":"https://api.github.com/repos/AnnaAK/assignments/subscribers","subscription_url":"https://api.github.com/repos/AnnaAK/assignments/subscription","commits_url":"https://api.github.com/repos/AnnaAK/assignments/commits{/sha}","git_commits_url":"https://api.github.com/repos/AnnaAK/assignments/git/commits{/sha}","comments_url":"https://api.github.com/repos/AnnaAK/assignments/comments{/number}","issue_comment_url":"https://api.github.com/repos/AnnaAK/assignments/issues/comments{/number}","contents_url":"https://api.github.com/repos/AnnaAK/assignments/contents/{+path}","compare_url":"https://api.github.com/repos/AnnaAK/assignments/compare/{base}...{head}","merges_url":"https://api.github.com/repos/AnnaAK/assignments/merges","archive_url":"https://api.github.com/repos/AnnaAK/assignments/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/AnnaAK/assignments/downloads","issues_url":"https://api.github.com/repos/AnnaAK/assignments/issues{/number}","pulls_url":"https://api.github.com/repos/AnnaAK/assignments/pulls{/number}","milestones_url":"https://api.github.com/repos/AnnaAK/assignments/milestones{/number}","notifications_url":"https://api.github.com/repos/AnnaAK/assignments/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/AnnaAK/assignments/labels{/name}","releases_url":"https://api.github.com/repos/AnnaAK/assignments/releases{/id}","created_at":"2015-10-06T07:48:10Z","updated_at":"2015-10-06T07:48:10Z","pushed_at":"2015-10-25T02:19:42Z","git_url":"git://github.com/AnnaAK/assignments.git","ssh_url":"git@github.com:AnnaAK/assignments.git","clone_url":"https://github.com/AnnaAK/assignments.git","svn_url":"https://github.com/AnnaAK/assignments","homepage":null,"size":279,"stargazers_count":0,"watchers_count":0,"language":"Kotlin","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"practice271:master","ref":"master","sha":"62b71f37ac55ed5a1947e89152d6509edd4639f6","user":{"login":"practice271","id":14125893,"avatar_url":"https://avatars.githubusercontent.com/u/14125893?v=3","gravatar_id":"","url":"https://api.github.com/users/practice271","html_url":"https://github.com/practice271","followers_url":"https://api.github.com/users/practice271/followers","following_url":"https://api.github.com/users/practice271/following{/other_user}","gists_url":"https://api.github.com/users/practice271/gists{/gist_id}","starred_url":"https://api.github.com/users/practice271/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/practice271/subscriptions","organizations_url":"https://api.github.com/users/practice271/orgs","repos_url":"https://api.github.com/users/practice271/repos","events_url":"https://api.github.com/users/practice271/events{/privacy}","received_events_url":"https://api.github.com/users/practice271/received_events","type":"Organization","site_admin":false},"repo":{"id":41914860,"name":"assignments","full_name":"practice271/assignments","owner":{"login":"practice271","id":14125893,"avatar_url":"https://avatars.githubusercontent.com/u/14125893?v=3","gravatar_id":"","url":"https://api.github.com/users/practice271","html_url":"https://github.com/practice271","followers_url":"https://api.github.com/users/practice271/followers","following_url":"https://api.github.com/users/practice271/following{/other_user}","gists_url":"https://api.github.com/users/practice271/gists{/gist_id}","starred_url":"https://api.github.com/users/practice271/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/practice271/subscriptions","organizations_url":"https://api.github.com/users/practice271/orgs","repos_url":"https://api.github.com/users/practice271/repos","events_url":"https://api.github.com/users/practice271/events{/privacy}","received_events_url":"https://api.github.com/users/practice271/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/practice271/assignments","description":"The repository to fork and complete assignments in it.","fork":false,"url":"https://api.github.com/repos/practice271/assignments","forks_url":"https://api.github.com/repos/practice271/assignments/forks","keys_url":"https://api.github.com/repos/practice271/assignments/keys{/key_id}","collaborators_url":"https://api.github.com/repos/practice271/assignments/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/practice271/assignments/teams","hooks_url":"https://api.github.com/repos/practice271/assignments/hooks","issue_events_url":"https://api.github.com/repos/practice271/assignments/issues/events{/number}","events_url":"https://api.github.com/repos/practice271/assignments/events","assignees_url":"https://api.github.com/repos/practice271/assignments/assignees{/user}","branches_url":"https://api.github.com/repos/practice271/assignments/branches{/branch}","tags_url":"https://api.github.com/repos/practice271/assignments/tags","blobs_url":"https://api.github.com/repos/practice271/assignments/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/practice271/assignments/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/practice271/assignments/git/refs{/sha}","trees_url":"https://api.github.com/repos/practice271/assignments/git/trees{/sha}","statuses_url":"https://api.github.com/repos/practice271/assignments/statuses/{sha}","languages_url":"https://api.github.com/repos/practice271/assignments/languages","stargazers_url":"https://api.github.com/repos/practice271/assignments/stargazers","contributors_url":"https://api.github.com/repos/practice271/assignments/contributors","subscribers_url":"https://api.github.com/repos/practice271/assignments/subscribers","subscription_url":"https://api.github.com/repos/practice271/assignments/subscription","commits_url":"https://api.github.com/repos/practice271/assignments/commits{/sha}","git_commits_url":"https://api.github.com/repos/practice271/assignments/git/commits{/sha}","comments_url":"https://api.github.com/repos/practice271/assignments/comments{/number}","issue_comment_url":"https://api.github.com/repos/practice271/assignments/issues/comments{/number}","contents_url":"https://api.github.com/repos/practice271/assignments/contents/{+path}","compare_url":"https://api.github.com/repos/practice271/assignments/compare/{base}...{head}","merges_url":"https://api.github.com/repos/practice271/assignments/merges","archive_url":"https://api.github.com/repos/practice271/assignments/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/practice271/assignments/downloads","issues_url":"https://api.github.com/repos/practice271/assignments/issues{/number}","pulls_url":"https://api.github.com/repos/practice271/assignments/pulls{/number}","milestones_url":"https://api.github.com/repos/practice271/assignments/milestones{/number}","notifications_url":"https://api.github.com/repos/practice271/assignments/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/practice271/assignments/labels{/name}","releases_url":"https://api.github.com/repos/practice271/assignments/releases{/id}","created_at":"2015-09-04T12:36:14Z","updated_at":"2015-10-01T13:39:12Z","pushed_at":"2015-10-25T11:49:01Z","git_url":"git://github.com/practice271/assignments.git","ssh_url":"git@github.com:practice271/assignments.git","clone_url":"https://github.com/practice271/assignments.git","svn_url":"https://github.com/practice271/assignments","homepage":null,"size":5808,"stargazers_count":2,"watchers_count":2,"language":"Kotlin","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":20,"mirror_url":null,"open_issues_count":21,"forks":20,"open_issues":21,"watchers":2,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/practice271/assignments/pulls/157"},"html":{"href":"https://github.com/practice271/assignments/pull/157"},"issue":{"href":"https://api.github.com/repos/practice271/assignments/issues/157"},"comments":{"href":"https://api.github.com/repos/practice271/assignments/issues/157/comments"},"review_comments":{"href":"https://api.github.com/repos/practice271/assignments/pulls/157/comments"},"review_comment":{"href":"https://api.github.com/repos/practice271/assignments/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/practice271/assignments/pulls/157/commits"},"statuses":{"href":"https://api.github.com/repos/practice271/assignments/statuses/4469dbabb4deba657a938d06204e7d4229f444aa"}}}}