Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

added classes #2274

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

added classes #2274

wants to merge 2 commits into from

Conversation

nooobas
Copy link

@nooobas nooobas commented Feb 3, 2025

No description provided.

Copy link

@mateacademy-ai-mentor mateacademy-ai-mentor left a comment

Choose a reason for hiding this comment

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

Thank you for your hard work on this project! 🚜 Your implementation is almost perfect, but there are a couple of critical issues that need to be addressed before we can approve the pull request:

  1. Incorrect Messages in Truck Class: The Truck class currently prints messages for a "Bulldozer" instead of a "Truck" in its doWork() and stopWork() methods. Please update these messages to accurately reflect the Truck class.

Once these changes are made, your code will be ready for approval. Keep up the great work, and don't hesitate to reach out if you have any questions! 😊

✨ Please rate this review in the Platform's notification center. I will be grateful for your feedback! ✨

🔄 Fix the issues, commit the changes, and then re-request my review using the Re-request review button in the Reviewers tab.

Comment on lines 6 to 7
public void doWork() {
System.out.println("Bulldozer started his work!");

Choose a reason for hiding this comment

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

The message in doWork should refer to 'Truck' instead of 'Bulldozer'. Change it to: System.out.println("Truck started his work!");

Comment on lines 11 to 12
public void stopWork() {
System.out.println("Bulldozer stopped his work!");

Choose a reason for hiding this comment

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

The message in stopWork should refer to 'Truck' instead of 'Bulldozer'. Change it to: System.out.println("Truck stopped his work!");

Copy link
Author

Choose a reason for hiding this comment

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

fixed truck message

Copy link

@mateacademy-ai-mentor mateacademy-ai-mentor left a comment

Choose a reason for hiding this comment

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

Great job on implementing the classes! 🎉 Your code meets the task requirements and demonstrates a solid understanding of object-oriented principles, particularly polymorphism. The Bulldozer, Excavator, and Truck classes are correctly extending the Machine class and overriding the necessary methods. The MainApp class effectively showcases how these classes work together.

You've successfully addressed the previous issue with the Truck class, ensuring that the doWork() and stopWork() methods now correctly reflect the actions of a truck. This shows your ability to incorporate feedback and improve your code.

While there are no critical issues, always remember to review and test your code thoroughly to catch any potential errors early. Keep up the great work, and continue to learn from each coding experience. Your dedication to improving your skills is commendable! 🚀

✨ Please rate this review in the Platform's notification center. I will be grateful for your feedback! ✨

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