Skip to content

Conversation

@lakylekidd
Copy link
Contributor

The new exercise should ask the students to return a list of trainers that have at least one pokemon.
These new trainer objects should also contain two additional variables, one that is an array and holds the list of their pokemons and the second one is an object that represents their gym.

This branch includes the solution as well as additional commenting for readability

@lakylekidd
Copy link
Contributor Author

Included two more exercises with solutions and changed the first exercise to include one of the other two to reduce code complexity.

Also, I have updated the fake datasets to work with new tests.

{ id: 8, name: 'Misty', pokemonIds: [120, 121] },
{ id: 9, name: 'Ash', pokemonIds: [25, 1, 7, 6, 17, 12] },
]
{ id: 1, name: "Brock", pokemonIds: [74, 95, 44] },
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Brock does not have a Gloom! ;)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reeeeally? So it is true!! I need to know pokemons to pass this course :P haha.... I needed this in order to get some variety in my tests.. dunno if we can use someone else, or maybe make up a new trainer.

})
);

return getTrainersAndGymsAndPokemons(gyms, trainers, pokemons)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is unreachable code ...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could be. I was making lots of tests I might have overlooked it. I'll check again.

lakylekidd and others added 3 commits June 10, 2019 22:58
Co-Authored-By: Rein Op 't Land <Reinoptland@gmail.com>
Co-Authored-By: Rein Op 't Land <Reinoptland@gmail.com>
Co-Authored-By: Rein Op 't Land <Reinoptland@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants