Fix git conflict#2591
Conversation
mateacademy-ai-mentor
left a comment
There was a problem hiding this comment.
Review Summary
Your implementation correctly satisfies all functional requirements for the OOP inheritance task. The abstract Machine class, three subclasses (Truck, Bulldozer, Excavator), polymorphism using a Machine[] array, and informative English messages are all properly implemented. The code will execute as expected. The only deviations are minor whitespace issues - redundant empty lines after method declarations in Bulldozer.java, Excavator.java, and empty lines between methods in MainApp.java. Per checklist item #1, these should be removed, though they are cosmetic and don't affect functionality. The core requirements and checklist items that impact task completion are all met.
✨ Please rate this review in the Platform's notification center1. I will be grateful for your feedback! ✨
Footnotes
| } | ||
|
|
There was a problem hiding this comment.
Redundant empty line after method declaration. Checklist item #1 specifies not to add empty lines after method signatures.
| } | ||
|
|
There was a problem hiding this comment.
Redundant empty line after method declaration. Checklist item #1 specifies not to add empty lines after method signatures.
| } | ||
|
|
There was a problem hiding this comment.
Redundant empty line after method declaration. Checklist item #1 specifies not to add empty lines after method signatures.
| public class MainApp { | ||
| public static void main(String[] args) { | ||
| Machine truck = new Truck(); | ||
| Machine bulldozer = new Bulldozer(); |
There was a problem hiding this comment.
Redundant empty line between methods. The checklist specifies to avoid empty lines after method declarations.
| public void doWork() { | ||
| System.out.println("Bulldozer started its work"); | ||
| } | ||
|
|
There was a problem hiding this comment.
Redundant empty line after method declaration. Per checklist item #1, avoid empty lines after class declaration or method signature.
| public void doWork() { | ||
| System.out.println("Bulldozer started its work"); | ||
| } | ||
|
|
There was a problem hiding this comment.
Redundant empty line after method declaration. Per checklist item #1, avoid empty lines after class declaration or method signature.
| @Override | ||
| public void doWork() { | ||
| System.out.println("Bulldozer started its work"); | ||
| } |
There was a problem hiding this comment.
Redundant empty line after method declaration. Per checklist item #1, avoid empty lines after class declaration or method signature.
| public void stopWork() { | ||
| System.out.println("Bulldozer stopped working"); | ||
| } | ||
| } |
There was a problem hiding this comment.
Redundant empty line before class closing brace. Per checklist item #1, avoid empty lines after method signatures or code blocks.
No description provided.