怎么使用Dog2这个引用?
package imooc;
public class Initial {
/**
* @param args
*/
public static void main(String[] args) {
// TODO Auto-generated method stub
dog Dog=new dog();
animal Animal = Dog;
if (Animal instanceof dog){
dog Dog2=(dog)Animal;
}else{
System.out.print("无法转换");
}
}
}