-
Homework
输入出生月份、日期以及性别,显示对应星座及性格(Enter the month, date and gender of birth to show the corresponding constellation and personality)
- 2020-06-24 00:00:08下载
- 积分:1
-
Exe4_3
3.已知车辆(Vehicle)包括机动车(MotoVehicle)和非机动车(NonMotorVehicle)2种。小汽车(Car)、公交车(Bus)等属于机动车,自行车(Bicycle)等属于非机动车。随着能源技术的发展,出现了电动自行车(ElectricBicycle)、电动小汽车(ElectricCar)、天然气公交车(NaturalGasBus)等新型车辆。车辆的共同特征是都能够运行(run),并且有唯一的5位车牌号(LicenseNumber)。机动车的共同特征是采用燃油发动机(FuelEngine),且能够驾驶(drive)。自行车的共同特征是能够骑行(ride)。电动车辆的共同特征是由电池(Battery)驱动。天然气车辆的共同特征是采用天然气(NaturalGas)作为动力。
要求:
(1)设计一个类体系描述上述车辆,写出它们的属性和方法。
(2)一家公司(Company)拥有10辆普通小汽车、5辆公交车、2辆电动小汽车和1辆天然气公交车,要求写一个方法listVehicles()显示所有车辆的信息(车牌号以及采用的动力)。
程序文件命名为Exe4_3.java。(3. Known vehicle (Vehicle) including motor vehicle (MotoVehicle) and non-motorized (NonMotorVehicle) 2 species. Cars (Car), bus (Bus), etc. to motor vehicles, bicycles (Bicycle), etc. are non-motor vehicles. With the development of energy technologies, the emergence of electric bicycles (ElectricBicycle), electric cars (ElectricCar), natural gas buses (NaturalGasBus) and other new vehicles. A common feature of the vehicle is able to run (run), and there are only five license plate number (LicenseNumber). Common feature is the use of a motor vehicle fuel engine (FuelEngine), and is capable of driving (drive). Common feature is the ability to ride a bike (ride). Common characteristics of the electric vehicle is driven by a battery (Battery). A common feature is the use of natural gas vehicles (NaturalGas) as the driving force.
Claim:
(1) describe the design of a class system of the vehicle, write their properties and methods.
(2) a company (Company) owns 10 ordinary cars, five buses, )
- 2015-06-14 18:22:51下载
- 积分:1
-
Bubbles
Java 开发的弹跳球小游戏代码. 便于理解OO的概念.(Bubbles Game, developed in Java, easy to understand OO design in Java)
- 2009-03-22 08:11:09下载
- 积分:1
-
Code_Examples
说明: 本资源提供了《大话Java——从零基础到数据库、Web开发》 书籍中的源代码,即书中范例部分的代码。希望对你们有用。(The resources of the " talking big Java- from zero to a database-based, Web development" books, the source code, that is part of the book example code. Hope that useful.)
- 2010-03-26 20:17:37下载
- 积分:1
-
ordering_s2180755112010-(1)
an ordering system in java
- 2013-08-22 22:38:20下载
- 积分:1
-
java-emul-finish
this is java emulator example maple
- 2013-03-19 23:42:29下载
- 积分:1
-
missing_close_brace
This PAC script is invalid, because there is a missing close brace on the function FindProxyForURL().
- 2014-01-26 16:53:39下载
- 积分:1
-
JAVA-calculator
JAVA-计算器JAVA-calculator
JAVA-calculator
(JAVA-Calculator JAVA-calculator JAVA-calculator)
- 2013-03-10 13:55:06下载
- 积分:1
-
0100_java_web_class5
将基础知识,高级运用,框架知识综合到一起,源码demo(Fundamentals and advanced the framework of the use of knowledge are integrated together, source demo)
- 2012-08-23 12:46:08下载
- 积分:1
-
TranslucentActivity
This demonstrates the how to write an activity that is translucent, allowing windows underneath to show through.
- 2014-03-03 11:28:03下载
- 积分:1