Valid 1Z0-804 Dumps shared by ExamDiscuss.com for Helping Passing 1Z0-804 Exam! ExamDiscuss.com now offer the newest 1Z0-804 exam dumps, the ExamDiscuss.com 1Z0-804 exam questions have been updated and answers have been corrected get the newest ExamDiscuss.com 1Z0-804 dumps with Test Engine here:
Given: public class Main { public static void main(String... ag) { Vehicle v = new SportsCar(); System.out.println(v.goes()); Tank t = (Tank) v; System.out.println(t); } } class Vehicle { public String goes() { return "goes "; }; } class SportsCar extends Vehicle { public String goes() { return "fast "; }; } class Tank extends Vehicle { public String goes() { return "slow "; }; } What is the result?
Correct Answer: E
Explanation/Reference: Explanation: Line:Vehicle v = new Sportscar(); causes compilation failure: error: cannot find symbol Vehicle v = new Sportscar(); symbol: class Sportscar location: class VehicleTest