Open Shewitttt opened 2 years ago
Week 1
Considering that you have followed the material only through the recording, you did great so far, looking at your fork. Hope you will find some time to do a few more. Have you also installed Mocha?
Thank you Daniel. Indeed I am trying the 'remove exclamation' now. Yes first I installed mocha then when I checked what my other classmates used it is jest so I installed that later on.
you are a pro π
Week 2
very nice work for the doctor/nurse exercise, even though it was super difficult to follow the class online last week!
well done! one more trick that you might have not seen is that Thibault used a for
loop in the test, to check for all years of experience..something like this:
describe(solution.name + ': mySolution', () => {
describe('When the premium is 200', () => {
for (let i=0; i<10; i++){
it('Should multiply by x1,2 when she has less than 10 year experience',
() => {
expect((solution({profession: 'nurse', experience: i}, 200))).toBe(240)
})
};
for (let i=10; i<15; i++){
it('Should multiply by x1,3 when she has 10 or more years of experience',
() => {
expect((solution({profession: 'nurse', experience: i}, 200))).toBe(260)
});
}
for (let i=15; i<20; i++){
it('Should multiply by x1,5 when she has 15 or more years of experience',
() => {
expect((solution({profession: 'nurse', experience: 15}, 200))).toBe(300)
});
}
for (let i=20; i<60; i++){
it('Should multiply by x1,7 when she has 20 or more years of experience',
() => {
expect((solution({profession: 'nurse', experience: 20}, 200))).toBe(340)
});
}
it('Should throw error if premium is above 500',
() => {
expect(()=> (solution({profession: 'nurse', experience}, 200))).toThrowError()
});
});
Thank you so much Daniel. I will take that in to consideration.
Week 3
Learning Objectives
Priorities: π₯, π£, π₯, π (click to learn more)
There is a lot to learn in this repository. If you can't master all the material at once, that's expected! Anything you don't master now will always be waiting for you to review when you need it. These 4 emoji's will help you prioritize your study time and to measure your progress: - π₯: Understanding this material is required, it covers the base skills you'll need to move on. You do not need to finish all of them but should feel comfortable that you could with enough time. - π£: You have started all of these exercises and feel you could complete them all if you just had more time. It may not be easy for you but with effort you can make it through. - π₯: You have studied the examples and started some exercises if you had time. You should have a big-picture understanding of these concepts/skills, but may not be confident completing the exercises. - π: These concepts or skills are not necessary but are related to this module. If you are finished with π₯, π£ and π₯ you can use the π exercises to push yourself without getting distracted from the module's main objectives. ---
1. Remix
Practice studying and remixing other people's solutions to coding challenges. Create your own solutions by mixing and matching pieces from other people's code.
2. Write
3. Review