摘要: 1 interface Car 2 { 3 // 汽车名称 4 String getName(); 5 6 // 获得汽车售价 7 int getPrice(); 8 } 9 // 宝马10 class BMW implements Car11 {12 public String getName()13 {14 return "BMW";15 }16 17 public int getPrice()18 {19 return 300000;20 }21 }22 // 奇瑞QQ23... 阅读全文
posted @ 2013-12-09 22:35 天天AC 阅读(174) 评论(0) 推荐(0)