{"action":"created","comment":{"url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/pulls/comments/183170234","pull_request_review_id":114127151,"id":183170234,"diff_hunk":"@@ -1,6 +1,72 @@\n # Your responses to the short answer questions should be laid out here using Mark Down.\n 1. Describe the biggest difference between `.forEach` & `.map`.\n+\n+`.forEach` simply performs the callback result on each element of the array.\n+* Because of this, `.forEach` is great for doing side effects, like `console.log()`, or pushing/popping things from arrays.\n+* Because it doesn't return anything, some kind of mutation is necessary to see its results. If you want to iterate over an array and do the callback function on each element, you'd have to change the array you're iterating over, or initialize a blank new array and change that to see any output.\n+\n+`.map` takes the each result of the callback functions and returns all of the results into a new array.\n+* Because of this, this doesn't need to change the array it is working on, nor do you need to set up an output array of your own. `map()` automatically returns a new array filled with results of the callback function iterating over the original array.\n+\n+\n+\n 2. What is the difference between a function and a method?\n+\n+A function and a method is inherently the same thing: a block of code that does an operation, such as transforming data. The only difference is that **a method is explicitly attached to an object**. \n+\n+Function:\n+```js\n+function bar() {\n+    return 'Hello';\n+}\n+bar();\n+```\n+\n+Method:\n+```js\n+const foo = {\n+    bar: function () {\n+        return 'Hello';\n+    },\n+}\n+foo.bar();\n+```\n+","path":"Answers.md","position":38,"original_position":34,"commit_id":"d68a5955501ca46c28e5d562b7016d53c938eeda","original_commit_id":"c2f14bfb12001d4d2a13ed4b4d55b6c87183109e","user":{"login":"JasonCorp84","id":26946454,"avatar_url":"https://avatars1.githubusercontent.com/u/26946454?v=4","gravatar_id":"","url":"https://api.github.com/users/JasonCorp84","html_url":"https://github.com/JasonCorp84","followers_url":"https://api.github.com/users/JasonCorp84/followers","following_url":"https://api.github.com/users/JasonCorp84/following{/other_user}","gists_url":"https://api.github.com/users/JasonCorp84/gists{/gist_id}","starred_url":"https://api.github.com/users/JasonCorp84/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JasonCorp84/subscriptions","organizations_url":"https://api.github.com/users/JasonCorp84/orgs","repos_url":"https://api.github.com/users/JasonCorp84/repos","events_url":"https://api.github.com/users/JasonCorp84/events{/privacy}","received_events_url":"https://api.github.com/users/JasonCorp84/received_events","type":"User","site_admin":false},"body":"Always great to have examples: keep it up! ","created_at":"2018-04-20T21:09:46Z","updated_at":"2018-04-20T21:09:46Z","html_url":"https://github.com/LambdaSchool/Sprint-Challenge--JavaScript/pull/257#discussion_r183170234","pull_request_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/pulls/257","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/pulls/comments/183170234"},"html":{"href":"https://github.com/LambdaSchool/Sprint-Challenge--JavaScript/pull/257#discussion_r183170234"},"pull_request":{"href":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/pulls/257"}}},"pull_request":{"url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/pulls/257","id":183043959,"html_url":"https://github.com/LambdaSchool/Sprint-Challenge--JavaScript/pull/257","diff_url":"https://github.com/LambdaSchool/Sprint-Challenge--JavaScript/pull/257.diff","patch_url":"https://github.com/LambdaSchool/Sprint-Challenge--JavaScript/pull/257.patch","issue_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/issues/257","number":257,"state":"open","locked":false,"title":"Ronald Libago - CS10 (Csaba Balogh)","user":{"login":"Mister-Corn","id":36778342,"avatar_url":"https://avatars1.githubusercontent.com/u/36778342?v=4","gravatar_id":"","url":"https://api.github.com/users/Mister-Corn","html_url":"https://github.com/Mister-Corn","followers_url":"https://api.github.com/users/Mister-Corn/followers","following_url":"https://api.github.com/users/Mister-Corn/following{/other_user}","gists_url":"https://api.github.com/users/Mister-Corn/gists{/gist_id}","starred_url":"https://api.github.com/users/Mister-Corn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Mister-Corn/subscriptions","organizations_url":"https://api.github.com/users/Mister-Corn/orgs","repos_url":"https://api.github.com/users/Mister-Corn/repos","events_url":"https://api.github.com/users/Mister-Corn/events{/privacy}","received_events_url":"https://api.github.com/users/Mister-Corn/received_events","type":"User","site_admin":false},"body":"**This is the PR for today's Sprint Challenge, 4/20/2018**\r\n\r\nIn acknowledgment of the \"3-hour time block\" of these challenges, I have a timestamp on commit updates with this format \"T+ (*time elapsed since start*)\". Any updates after \"T+ 3hr\" would be labelled as \"Overtime\".\r\n\r\n## Main Goals\r\n\r\n- [x] Study Questions\r\n- [x] Challenge 1: Objects and Arrays\r\n- [x] Challenge 2: Functions\r\n- [x] Challenge 3: Prototypes\r\n- [x] Challenge 4: Classes\r\n\r\n## Stretch Goal\r\n- [x] A companion cube lovingly crafted with classes.\r\n------\r\nStudent: Ronald Libago\r\nClass: CS10\r\nPM: Csaba Balogh","created_at":"2018-04-20T12:11:48Z","updated_at":"2018-04-20T21:09:46Z","closed_at":null,"merged_at":null,"merge_commit_sha":"2695048aab27fc4bddae912661e5983a813f12ef","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/pulls/257/commits","review_comments_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/pulls/257/comments","review_comment_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/pulls/comments{/number}","comments_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/issues/257/comments","statuses_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/statuses/d68a5955501ca46c28e5d562b7016d53c938eeda","head":{"label":"Mister-Corn:master","ref":"master","sha":"d68a5955501ca46c28e5d562b7016d53c938eeda","user":{"login":"Mister-Corn","id":36778342,"avatar_url":"https://avatars1.githubusercontent.com/u/36778342?v=4","gravatar_id":"","url":"https://api.github.com/users/Mister-Corn","html_url":"https://github.com/Mister-Corn","followers_url":"https://api.github.com/users/Mister-Corn/followers","following_url":"https://api.github.com/users/Mister-Corn/following{/other_user}","gists_url":"https://api.github.com/users/Mister-Corn/gists{/gist_id}","starred_url":"https://api.github.com/users/Mister-Corn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Mister-Corn/subscriptions","organizations_url":"https://api.github.com/users/Mister-Corn/orgs","repos_url":"https://api.github.com/users/Mister-Corn/repos","events_url":"https://api.github.com/users/Mister-Corn/events{/privacy}","received_events_url":"https://api.github.com/users/Mister-Corn/received_events","type":"User","site_admin":false},"repo":{"id":130355656,"name":"Sprint-Challenge--JavaScript","full_name":"Mister-Corn/Sprint-Challenge--JavaScript","owner":{"login":"Mister-Corn","id":36778342,"avatar_url":"https://avatars1.githubusercontent.com/u/36778342?v=4","gravatar_id":"","url":"https://api.github.com/users/Mister-Corn","html_url":"https://github.com/Mister-Corn","followers_url":"https://api.github.com/users/Mister-Corn/followers","following_url":"https://api.github.com/users/Mister-Corn/following{/other_user}","gists_url":"https://api.github.com/users/Mister-Corn/gists{/gist_id}","starred_url":"https://api.github.com/users/Mister-Corn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Mister-Corn/subscriptions","organizations_url":"https://api.github.com/users/Mister-Corn/orgs","repos_url":"https://api.github.com/users/Mister-Corn/repos","events_url":"https://api.github.com/users/Mister-Corn/events{/privacy}","received_events_url":"https://api.github.com/users/Mister-Corn/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Mister-Corn/Sprint-Challenge--JavaScript","description":null,"fork":true,"url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript","forks_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/forks","keys_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/teams","hooks_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/hooks","issue_events_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/issues/events{/number}","events_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/events","assignees_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/assignees{/user}","branches_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/branches{/branch}","tags_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/tags","blobs_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/git/refs{/sha}","trees_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/statuses/{sha}","languages_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/languages","stargazers_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/stargazers","contributors_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/contributors","subscribers_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/subscribers","subscription_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/subscription","commits_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/commits{/sha}","git_commits_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/git/commits{/sha}","comments_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/comments{/number}","issue_comment_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/issues/comments{/number}","contents_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/contents/{+path}","compare_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/merges","archive_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/downloads","issues_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/issues{/number}","pulls_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/pulls{/number}","milestones_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/milestones{/number}","notifications_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/labels{/name}","releases_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/releases{/id}","deployments_url":"https://api.github.com/repos/Mister-Corn/Sprint-Challenge--JavaScript/deployments","created_at":"2018-04-20T11:54:11Z","updated_at":"2018-04-20T15:12:16Z","pushed_at":"2018-04-20T15:12:14Z","git_url":"git://github.com/Mister-Corn/Sprint-Challenge--JavaScript.git","ssh_url":"git@github.com:Mister-Corn/Sprint-Challenge--JavaScript.git","clone_url":"https://github.com/Mister-Corn/Sprint-Challenge--JavaScript.git","svn_url":"https://github.com/Mister-Corn/Sprint-Challenge--JavaScript","homepage":null,"size":99,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","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":"LambdaSchool:master","ref":"master","sha":"8d381d8a2cb506eb751da1374cf980ee92604268","user":{"login":"LambdaSchool","id":24780114,"avatar_url":"https://avatars1.githubusercontent.com/u/24780114?v=4","gravatar_id":"","url":"https://api.github.com/users/LambdaSchool","html_url":"https://github.com/LambdaSchool","followers_url":"https://api.github.com/users/LambdaSchool/followers","following_url":"https://api.github.com/users/LambdaSchool/following{/other_user}","gists_url":"https://api.github.com/users/LambdaSchool/gists{/gist_id}","starred_url":"https://api.github.com/users/LambdaSchool/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LambdaSchool/subscriptions","organizations_url":"https://api.github.com/users/LambdaSchool/orgs","repos_url":"https://api.github.com/users/LambdaSchool/repos","events_url":"https://api.github.com/users/LambdaSchool/events{/privacy}","received_events_url":"https://api.github.com/users/LambdaSchool/received_events","type":"Organization","site_admin":false},"repo":{"id":110197874,"name":"Sprint-Challenge--JavaScript","full_name":"LambdaSchool/Sprint-Challenge--JavaScript","owner":{"login":"LambdaSchool","id":24780114,"avatar_url":"https://avatars1.githubusercontent.com/u/24780114?v=4","gravatar_id":"","url":"https://api.github.com/users/LambdaSchool","html_url":"https://github.com/LambdaSchool","followers_url":"https://api.github.com/users/LambdaSchool/followers","following_url":"https://api.github.com/users/LambdaSchool/following{/other_user}","gists_url":"https://api.github.com/users/LambdaSchool/gists{/gist_id}","starred_url":"https://api.github.com/users/LambdaSchool/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/LambdaSchool/subscriptions","organizations_url":"https://api.github.com/users/LambdaSchool/orgs","repos_url":"https://api.github.com/users/LambdaSchool/repos","events_url":"https://api.github.com/users/LambdaSchool/events{/privacy}","received_events_url":"https://api.github.com/users/LambdaSchool/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/LambdaSchool/Sprint-Challenge--JavaScript","description":null,"fork":false,"url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript","forks_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/forks","keys_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/keys{/key_id}","collaborators_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/teams","hooks_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/hooks","issue_events_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/issues/events{/number}","events_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/events","assignees_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/assignees{/user}","branches_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/branches{/branch}","tags_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/tags","blobs_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/git/refs{/sha}","trees_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/git/trees{/sha}","statuses_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/statuses/{sha}","languages_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/languages","stargazers_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/stargazers","contributors_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/contributors","subscribers_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/subscribers","subscription_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/subscription","commits_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/commits{/sha}","git_commits_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/git/commits{/sha}","comments_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/comments{/number}","issue_comment_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/issues/comments{/number}","contents_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/contents/{+path}","compare_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/compare/{base}...{head}","merges_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/merges","archive_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/downloads","issues_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/issues{/number}","pulls_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/pulls{/number}","milestones_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/milestones{/number}","notifications_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/labels{/name}","releases_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/releases{/id}","deployments_url":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/deployments","created_at":"2017-11-10T03:28:17Z","updated_at":"2018-04-20T14:51:17Z","pushed_at":"2018-04-20T21:05:22Z","git_url":"git://github.com/LambdaSchool/Sprint-Challenge--JavaScript.git","ssh_url":"git@github.com:LambdaSchool/Sprint-Challenge--JavaScript.git","clone_url":"https://github.com/LambdaSchool/Sprint-Challenge--JavaScript.git","svn_url":"https://github.com/LambdaSchool/Sprint-Challenge--JavaScript","homepage":null,"size":87,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":315,"mirror_url":null,"archived":false,"open_issues_count":51,"license":null,"forks":315,"open_issues":51,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/pulls/257"},"html":{"href":"https://github.com/LambdaSchool/Sprint-Challenge--JavaScript/pull/257"},"issue":{"href":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/issues/257"},"comments":{"href":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/issues/257/comments"},"review_comments":{"href":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/pulls/257/comments"},"review_comment":{"href":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/pulls/257/commits"},"statuses":{"href":"https://api.github.com/repos/LambdaSchool/Sprint-Challenge--JavaScript/statuses/d68a5955501ca46c28e5d562b7016d53c938eeda"}},"author_association":"NONE"}}
{"actor":{"display_login":"JasonCorp84"}}