{"action":"created","comment":{"url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pulls/comments/57584631","id":57584631,"diff_hunk":"@@ -4,25 +4,41 @@\n // Write a function that takes zero or more arguments\n // and returns the minimum from that set\n // assume that all the argument are numbers\n-const min = function min() {\n-\n+const min = function min(a, b) {\n+  if (a < b) {\n+    return a;\n+  } else if (b < a) {\n+    return b;\n+  }\n };\n \n+// I'm not sure on how to accept zero arguments, unless its as simple as\n+// leaving the () empty\n+\n+\n // Question 2\n // Write a function that takes zero or more arguments\n // and returns the sum of that set\n // assume that all the argument are numbers\n-const sum = function sum() {\n-\n+const sum = function sum(a, b) {\n+  return a + b;\n };\n \n+\n+\n // Question 3\n // Write a function that returns an array of the specified length\n // with all the elements set to defaultValue\n const newArray = function newArray(length, defaultValue) {\n+  return newArray (length(defaultValue));\n+","path":"lib/diagnostic.js","position":35,"original_position":35,"commit_id":"744caf1c86cc360b2252a6a461195682ada6b33a","original_commit_id":"744caf1c86cc360b2252a6a461195682ada6b33a","user":{"login":"RDegnen","id":8826469,"avatar_url":"https://avatars.githubusercontent.com/u/8826469?v=3","gravatar_id":"","url":"https://api.github.com/users/RDegnen","html_url":"https://github.com/RDegnen","followers_url":"https://api.github.com/users/RDegnen/followers","following_url":"https://api.github.com/users/RDegnen/following{/other_user}","gists_url":"https://api.github.com/users/RDegnen/gists{/gist_id}","starred_url":"https://api.github.com/users/RDegnen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RDegnen/subscriptions","organizations_url":"https://api.github.com/users/RDegnen/orgs","repos_url":"https://api.github.com/users/RDegnen/repos","events_url":"https://api.github.com/users/RDegnen/events{/privacy}","received_events_url":"https://api.github.com/users/RDegnen/received_events","type":"User","site_admin":false},"body":"```\r\nconst newArray = function newArray(length, defaultValue) {\r\n  let array = new Array(length);\r\n  for (let i = 0; i < length; i++) {\r\n    array[i] = typeof defaultValue === 'function' ?\r\n      defaultValue(i) : defaultValue;\r\n  }\r\n\r\n  return array;\r\n};\r\n```","created_at":"2016-03-28T15:30:37Z","updated_at":"2016-03-28T15:30:37Z","html_url":"https://github.com/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pull/75#discussion_r57584631","pull_request_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pulls/75","_links":{"self":{"href":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pulls/comments/57584631"},"html":{"href":"https://github.com/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pull/75#discussion_r57584631"},"pull_request":{"href":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pulls/75"}}},"pull_request":{"url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pulls/75","id":64321481,"html_url":"https://github.com/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pull/75","diff_url":"https://github.com/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pull/75.diff","patch_url":"https://github.com/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pull/75.patch","issue_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/issues/75","number":75,"state":"open","locked":false,"title":"js-functions-ins-and-outs-diagnostic","user":{"login":"Benjamski","id":16841950,"avatar_url":"https://avatars.githubusercontent.com/u/16841950?v=3","gravatar_id":"","url":"https://api.github.com/users/Benjamski","html_url":"https://github.com/Benjamski","followers_url":"https://api.github.com/users/Benjamski/followers","following_url":"https://api.github.com/users/Benjamski/following{/other_user}","gists_url":"https://api.github.com/users/Benjamski/gists{/gist_id}","starred_url":"https://api.github.com/users/Benjamski/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Benjamski/subscriptions","organizations_url":"https://api.github.com/users/Benjamski/orgs","repos_url":"https://api.github.com/users/Benjamski/repos","events_url":"https://api.github.com/users/Benjamski/events{/privacy}","received_events_url":"https://api.github.com/users/Benjamski/received_events","type":"User","site_admin":false},"body":"Started going through codeschool heavily over the weekend and those examples\r\nseem to be helping build my understanding a lot, but I'm still catching up much\r\nslower than the pace of the course.","created_at":"2016-03-28T13:29:36Z","updated_at":"2016-03-28T15:30:37Z","closed_at":null,"merged_at":null,"merge_commit_sha":"3d4f79249a2d060113e53d3dee11e6eab229bfcb","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pulls/75/commits","review_comments_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pulls/75/comments","review_comment_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/issues/75/comments","statuses_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/statuses/744caf1c86cc360b2252a6a461195682ada6b33a","head":{"label":"Benjamski:response","ref":"response","sha":"744caf1c86cc360b2252a6a461195682ada6b33a","user":{"login":"Benjamski","id":16841950,"avatar_url":"https://avatars.githubusercontent.com/u/16841950?v=3","gravatar_id":"","url":"https://api.github.com/users/Benjamski","html_url":"https://github.com/Benjamski","followers_url":"https://api.github.com/users/Benjamski/followers","following_url":"https://api.github.com/users/Benjamski/following{/other_user}","gists_url":"https://api.github.com/users/Benjamski/gists{/gist_id}","starred_url":"https://api.github.com/users/Benjamski/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Benjamski/subscriptions","organizations_url":"https://api.github.com/users/Benjamski/orgs","repos_url":"https://api.github.com/users/Benjamski/repos","events_url":"https://api.github.com/users/Benjamski/events{/privacy}","received_events_url":"https://api.github.com/users/Benjamski/received_events","type":"User","site_admin":false},"repo":{"id":54892453,"name":"js-functions-ins-and-outs-diagnostic","full_name":"Benjamski/js-functions-ins-and-outs-diagnostic","owner":{"login":"Benjamski","id":16841950,"avatar_url":"https://avatars.githubusercontent.com/u/16841950?v=3","gravatar_id":"","url":"https://api.github.com/users/Benjamski","html_url":"https://github.com/Benjamski","followers_url":"https://api.github.com/users/Benjamski/followers","following_url":"https://api.github.com/users/Benjamski/following{/other_user}","gists_url":"https://api.github.com/users/Benjamski/gists{/gist_id}","starred_url":"https://api.github.com/users/Benjamski/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Benjamski/subscriptions","organizations_url":"https://api.github.com/users/Benjamski/orgs","repos_url":"https://api.github.com/users/Benjamski/repos","events_url":"https://api.github.com/users/Benjamski/events{/privacy}","received_events_url":"https://api.github.com/users/Benjamski/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Benjamski/js-functions-ins-and-outs-diagnostic","description":"Assessment JavaScript Functions - \"Ins & Outs\"","fork":true,"url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic","forks_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/forks","keys_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/teams","hooks_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/hooks","issue_events_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/issues/events{/number}","events_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/events","assignees_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/assignees{/user}","branches_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/branches{/branch}","tags_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/tags","blobs_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/git/refs{/sha}","trees_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/statuses/{sha}","languages_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/languages","stargazers_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/stargazers","contributors_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/contributors","subscribers_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/subscribers","subscription_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/subscription","commits_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/commits{/sha}","git_commits_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/git/commits{/sha}","comments_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/comments{/number}","issue_comment_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/issues/comments{/number}","contents_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/contents/{+path}","compare_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/merges","archive_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/downloads","issues_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/issues{/number}","pulls_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/pulls{/number}","milestones_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/milestones{/number}","notifications_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/labels{/name}","releases_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/releases{/id}","deployments_url":"https://api.github.com/repos/Benjamski/js-functions-ins-and-outs-diagnostic/deployments","created_at":"2016-03-28T13:01:03Z","updated_at":"2016-03-28T13:01:03Z","pushed_at":"2016-03-28T13:29:18Z","git_url":"git://github.com/Benjamski/js-functions-ins-and-outs-diagnostic.git","ssh_url":"git@github.com:Benjamski/js-functions-ins-and-outs-diagnostic.git","clone_url":"https://github.com/Benjamski/js-functions-ins-and-outs-diagnostic.git","svn_url":"https://github.com/Benjamski/js-functions-ins-and-outs-diagnostic","homepage":null,"size":19,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","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":"ga-wdi-boston:master","ref":"master","sha":"08322e3dffb21d5df65512c59734122ccdb9ce25","user":{"login":"ga-wdi-boston","id":6361298,"avatar_url":"https://avatars.githubusercontent.com/u/6361298?v=3","gravatar_id":"","url":"https://api.github.com/users/ga-wdi-boston","html_url":"https://github.com/ga-wdi-boston","followers_url":"https://api.github.com/users/ga-wdi-boston/followers","following_url":"https://api.github.com/users/ga-wdi-boston/following{/other_user}","gists_url":"https://api.github.com/users/ga-wdi-boston/gists{/gist_id}","starred_url":"https://api.github.com/users/ga-wdi-boston/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ga-wdi-boston/subscriptions","organizations_url":"https://api.github.com/users/ga-wdi-boston/orgs","repos_url":"https://api.github.com/users/ga-wdi-boston/repos","events_url":"https://api.github.com/users/ga-wdi-boston/events{/privacy}","received_events_url":"https://api.github.com/users/ga-wdi-boston/received_events","type":"Organization","site_admin":false},"repo":{"id":43652662,"name":"js-functions-ins-and-outs-diagnostic","full_name":"ga-wdi-boston/js-functions-ins-and-outs-diagnostic","owner":{"login":"ga-wdi-boston","id":6361298,"avatar_url":"https://avatars.githubusercontent.com/u/6361298?v=3","gravatar_id":"","url":"https://api.github.com/users/ga-wdi-boston","html_url":"https://github.com/ga-wdi-boston","followers_url":"https://api.github.com/users/ga-wdi-boston/followers","following_url":"https://api.github.com/users/ga-wdi-boston/following{/other_user}","gists_url":"https://api.github.com/users/ga-wdi-boston/gists{/gist_id}","starred_url":"https://api.github.com/users/ga-wdi-boston/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ga-wdi-boston/subscriptions","organizations_url":"https://api.github.com/users/ga-wdi-boston/orgs","repos_url":"https://api.github.com/users/ga-wdi-boston/repos","events_url":"https://api.github.com/users/ga-wdi-boston/events{/privacy}","received_events_url":"https://api.github.com/users/ga-wdi-boston/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ga-wdi-boston/js-functions-ins-and-outs-diagnostic","description":"Assessment JavaScript Functions - \"Ins & Outs\"","fork":false,"url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic","forks_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/forks","keys_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/teams","hooks_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/hooks","issue_events_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/issues/events{/number}","events_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/events","assignees_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/assignees{/user}","branches_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/branches{/branch}","tags_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/tags","blobs_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/git/refs{/sha}","trees_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/statuses/{sha}","languages_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/languages","stargazers_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/stargazers","contributors_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/contributors","subscribers_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/subscribers","subscription_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/subscription","commits_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/commits{/sha}","git_commits_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/git/commits{/sha}","comments_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/comments{/number}","issue_comment_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/issues/comments{/number}","contents_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/contents/{+path}","compare_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/merges","archive_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/downloads","issues_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/issues{/number}","pulls_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pulls{/number}","milestones_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/milestones{/number}","notifications_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/labels{/name}","releases_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/releases{/id}","deployments_url":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/deployments","created_at":"2015-10-04T21:02:56Z","updated_at":"2016-01-20T19:42:09Z","pushed_at":"2016-03-28T13:37:39Z","git_url":"git://github.com/ga-wdi-boston/js-functions-ins-and-outs-diagnostic.git","ssh_url":"git@github.com:ga-wdi-boston/js-functions-ins-and-outs-diagnostic.git","clone_url":"https://github.com/ga-wdi-boston/js-functions-ins-and-outs-diagnostic.git","svn_url":"https://github.com/ga-wdi-boston/js-functions-ins-and-outs-diagnostic","homepage":null,"size":72,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":64,"mirror_url":null,"open_issues_count":7,"forks":64,"open_issues":7,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pulls/75"},"html":{"href":"https://github.com/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pull/75"},"issue":{"href":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/issues/75"},"comments":{"href":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/issues/75/comments"},"review_comments":{"href":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pulls/75/comments"},"review_comment":{"href":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/pulls/75/commits"},"statuses":{"href":"https://api.github.com/repos/ga-wdi-boston/js-functions-ins-and-outs-diagnostic/statuses/744caf1c86cc360b2252a6a461195682ada6b33a"}}}}