Skip to content

Commit 4e6ea29

Browse files
authored
Merge pull request #3 from leachcoding/jay-leach
edits are now done
2 parents 7456ec8 + c9e6fa9 commit 4e6ea29

File tree

2 files changed

+8
-11
lines changed

2 files changed

+8
-11
lines changed

challenges/functions.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
// Step 1: Create a higher-order function that will accept 3 parameters. The first two can take any argument. The last is your callback. This function should return your callback that passed the first two parameters as its argument.
55

6-
/* Step 2: Create several functions.
6+
/* Step 2: Create several functions that you will callback with the previous higher order function.
77
The first will return the sum of two numbers.
88
The second will return the product of two numbers.
99
The third will return the modulus of the two numbers.

challenges/objects-arrays.js

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -28,15 +28,12 @@ What is the length of all 3 objects
2828

2929
const gameCharacters = [
3030
{id: 1, name: "Mario", game: "Super Mario World", mission: "Save the Princess", enemy: "Bowser", subEnemies: ["Koopa", "Goomba", "BowserJr"]},
31-
{id: 2, name: "Mario", game: "Super Mario World", mission: "Save the Princess", enemy: "Bowser", subEnemies: ["Koopa", "Goomba", "BowserJr"]},
32-
{id: 3, name: "Mario", game: "Super Mario World", mission: "Save the Princess", enemy: "Bowser", subEnemies: ["Koopa", "Goomba", "BowserJr"]},
33-
{id: 4, name: "Mario", game: "Super Mario World", mission: "Save the Princess", enemy: "Bowser", subEnemies: ["Koopa", "Goomba", "BowserJr"]},
34-
{id: 5, name: "Mario", game: "Super Mario World", mission: "Save the Princess", enemy: "Bowser", subEnemies: ["Koopa", "Goomba", "BowserJr"]},
35-
{id: 6, name: "Mario", game: "Super Mario World", mission: "Save the Princess", enemy: "Bowser", subEnemies: ["Koopa", "Goomba", "BowserJr"]},
36-
{id: 7, name: "Mario", game: "Super Mario World", mission: "Save the Princess", enemy: "Bowser", subEnemies: ["Koopa", "Goomba", "BowserJr"]},
37-
{id: 8, name: "Mario", game: "Super Mario World", mission: "Save the Princess", enemy: "Bowser", subEnemies: ["Koopa", "Goomba", "BowserJr"]},
38-
{id: 9, name: "Mario", game: "Super Mario World", mission: "Save the Princess", enemy: "Bowser", subEnemies: ["Koopa", "Goomba", "BowserJr"]},
39-
{id: 10, name: "Mario", game: "Super Mario World", mission: "Save the Princess", enemy: "Bowser", subEnemies: ["Koopa", "Goomba", "BowserJr"]}
31+
{id: 2, name: "Clank", game: "Ratchet & Clank", mission: "Save the Universe", enemy: "Robot", subEnemies: ["small animal", "small robot", "mini boss"]},
32+
{id: 3, name: "Master Chief", game: "Halo", mission: "Save the Universe", enemy: "Covenant", subEnemies: ["small shooters", "snipers", "elite"]},
33+
{id: 4, name: "Donkey Kong", game: "Donkey Kong Country", mission: "Get bananas back", enemy: "Kroc", subEnemies: ["snakes", "gators", "bees"]},
34+
{id: 5, name: "Sonic", game: "Sonic the Hedgehog", mission: "collect coins", enemy: "Dr Eggman", subEnemies: ["lasers", "spikes", "shooters"]},
35+
{id: 6, name: "Jak", game: "Jak & Dexter", mission: "Get back life", enemy: "main boss", subEnemies: ["miniboss", "blaster", "shooter"]},
36+
4037
];
4138

4239
// Step 1: Create a new array that will contain all games. Once you have it made, sort it ascending[A-Z]. Log the result. Solve two ways:
@@ -53,7 +50,7 @@ const gameCharacters = [
5350
// Map or forEach
5451

5552

56-
// Step 3: Find out how many sub enemies are in each character. Display the number as well as the array. Solve two ways
53+
// Step 3: Find out how many sub enemies are in each character. Display the number as well as the array. After you have displayed it, then take out the first sub enemy of each character and return the new results. Solve two ways
5754

5855
// For Loop
5956

0 commit comments

Comments
 (0)