public class Forum { public static void sayIt(Speaker s) { s.speak(); } public static void main(String[] args) { Speaker current; current = new Philosopher(); current.speak(); current = new Professor(); current.speak(); sayIt(current); // the same thing as above //current.pontificate(); //compile error // Use a cast ((Professor)current).pontificate(); } }