Change polymorphism Main.java