Help ples
1. Repair the logic of the someAction method for the solutionAction field.
2. See the comment on the main method for example output.
3. Hint: if param > 0, then the someAction method of an anonymous class in the solutionAction field should call a method of the FirstClass subclass.
Otherwise, call a method of the SecondClass subclass.
Don't change the main method!
Requirements:
- The screen output must match the task conditions.
- The string constants declared in the SecondClass class should be used for the output.
- The someAction method of the Action anonymous class created in the Solution class must call the someAction method of the parent class (super.someAction()).
- A FirstClass object must be created in the someAction method of the Action anonymous class created in the Solution class.
- A SecondClass object must be created in the someAction method of the Action anonymous class created in the Solution class.
package com.codegym.task.task24.task2405;
public interface Action {
void someAction();
}