-
-
Notifications
You must be signed in to change notification settings - Fork 184
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
oop-exercise #614
base: main
Are you sure you want to change the base?
oop-exercise #614
Conversation
Hey! Congratulations on your PR! 😎😎😎 Let's do some self-checks to fix most common issues and to make some improvements to the code before reviewers put their hands on the code. Go through the requirements/most common mistakes linked below and fix the code as appropriate. If you have any questions to requirements/common mistakes feel free asking them here or in Students' chat. When you genuinely believe you are done put a comment stating that you have completed self-checks and fixed code accordingly. Also, be aware, that if you would silently ignore this recommendation, a mentor can think that you are still working on fixes. And your PR will not be reviewed. 😒 Please, make sure that your code follows the requirements based on the most common mistakes as well as both basic and advanced requirements from the original task. Universal recommendations:
By the way, you may proceed to the next task before this one is reviewed and merged. Sincerely yours, |
Please, review. |
@kirill8210 please do what the bot asks to do. |
Сhecked my work but could not find anything that could be corrected |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@kirill8210 double-check yourself against requirements. Ask questions if anything is not clear. Do not expect mentors to do checks for you. Self-check, due attention, asking questions is a part of a software developer's skillset.
Same refers to your other submissions.
this.saying = saying; | ||
} | ||
getShow(){ | ||
return `${this.species}; ${this.name}; ${this.gender}; ${this.saying};` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Make this line of code DRY using an appropriate Array
method.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
applied the map method
class Animals extends Inhabitant{ | ||
constructor(species, name, gender, saying, legs) { | ||
super(species, name, gender, saying); | ||
this.legs = legs; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Make code DRYer by using OOP principles.
Why legs
and e.g. name
are treated in different ways?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed legs to paws that only animals have
let cat = new Animals('cat', 'Tom', 'male','May!', 4); | ||
let dog = new Animals('dog', 'Toby', 'male','Gav!', 4); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Each species is represented with its own class
"Animals" is not a species.
There is no need to specify species at instantiation yet species are printed
We specify species here as parameters.
Also men and women belong to the same species.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
added cat, dog classes
Fixed bugs, on some points consulted in the student chat. Please, review. |
This issue has been automatically marked as stale because there were no activity during last 14 days. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. А. Чому так? Б. Що робити, якщо в піарі нема оновлень, оскільки не зрозуміло, що треба зробити? В. А якщо я все зробив(ла) і це ментор не рев'юває мої зміни?
Г. Хіба недостатньо того, що я додав(ла) коміт із змінами? Традиційна пропозиція: задай питання по вищенаписаному в студентському чаті. |
oop-exercise
Demo |
Code base
The code is submitted in a dedicated feature branch.
Only code files are submitted.
Please, review.