Untitled

mail@pastecode.io avatar
unknown
java
2 years ago
425 B
0
Indexable
Never
package main.java;

public class Test {
    public static void main(String[] args) {
        // Warm up exercise
        //create a class named Developer that extends the Employee 
        //and when the speak method is called, 
        //the System out should be "I'm a Developer"

        Employee emp1 = new Employee();
        emp1.speak();

        Employee emp2 = new Developer();
        emp2.speak();
        
    }
}