Skip to content

Conversation

@bim121
Copy link

@bim121 bim121 commented Oct 5, 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.

Review Summary

Decision: APPROVE — Functionality is correct and all core requirements are met.

Your implementation correctly defines Machine as abstract, implements Truck, Bulldozer, and Excavator with proper doWork()/stopWork() overrides, and uses polymorphism in MainApp to iterate and invoke both methods. The only issues found are minor style violations related to redundant blank lines [CHECKLIST ITEM #1]:

  • Machine.java: remove the empty line between doWork() and stopWork() (around line 5).
  • Bulldozer.java: remove the blank line between doWork() and @Override stopWork() (around line 8).
  • Truck.java: remove the blank line between the two methods (around line 8).
  • Excavator.java: remove the blank line after the package declaration and the one between doWork() and @Override stopWork().

These are non-blocking and easy to fix. Nice job on clean, readable methods and correct use of polymorphism—please tidy the blank lines to align with the checklist.


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

Footnotes

  1. Rate AI review example

public void doWork() {
System.out.println("Bulldozer started its work");
}

Choose a reason for hiding this comment

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

This violates checklist item #1: "Do not add redundant empty lines after class declarations or method signatures". There is an extra blank line at line 8 between the end of doWork() and the @Override of stopWork() — remove that blank line so the method declarations appear consecutively. Refer to the checklist for the rule.

@@ -0,0 +1,13 @@
package core.basesyntax;

Choose a reason for hiding this comment

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

This violates checklist item #1: "Do not add redundant empty lines after class declarations or method signatures". Remove the empty line after the package declaration so there are no redundant blank lines between package and the class declaration.

public void doWork() {
System.out.println("Excavator started its work");
}

Choose a reason for hiding this comment

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

This violates checklist item #1: "Do not add redundant empty lines after class declarations or method signatures". Remove the empty line between the end of doWork() and the @Override for stopWork() so the methods appear consecutively without redundant blank lines.


public abstract class Machine {
public abstract void doWork();

Choose a reason for hiding this comment

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

This violates checklist item #1: "Please don't add redundant empty lines to your code. We don't need them after class declaration or method signature."

There is a redundant empty line between the doWork() and stopWork() declarations. Remove the blank line at line 5 so the method declarations appear consecutively.

public void doWork() {
System.out.println("Truck started its work");
}

Choose a reason for hiding this comment

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

This violates checklist item #1: "Please don't add redundant empty lines to your code. We don't need them after class declaration or method signature."

There is a redundant empty line between the doWork() and stopWork() methods (remove the blank line at line 8 so the methods appear consecutively).

@bim121 bim121 closed this by deleting the head repository Nov 25, 2025
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