PRN212_-_PE_-_SP_2025_-_Block_5_3856.webp
Izumi99

PRN212_-_PE_-_SP_2025_-_Block_5_3856.webp

  • Media owner Izumi99
  • Ngày thêm
Kizspy.me
Zoom
⚫ Just one of above requirements is violated, your work will be considered as invalid.
On completion, submit the whole solution folder.
Before submitting, you can delete the folder [bin] in each project to reduce the size of the solution, to
fit the requirements of PEA_Client.
Question 1 (4 points): Design a Vehicle Speed Adjustment System
Design a C# console application that meet the following requirements:
1. Create an abstract class Vehicle with:
-
Private fields: string name, int speed.
-
Constructor: public Vehicle(string name, int speed) to initialize name and speed.
Public properties: Name, Speed for get and set value of fields: name and speed.
Abstract method: string DescribeMovement().
2. Create a class Car that inherits from Vehicle:
Implement DescribeMovement() to return: "[name] is driving at [speed] km/h".
3. Create a class Bicycle that inherits from Vehicle:
Implement DescribeMovement() to return: "[name] is pedaling at [speed] km/h".
+ 100%
Close
Chưa có bình luận nào.

Thông tin

Category
PRN212
Thêm bởi
Izumi99
Ngày thêm
Lượt xem
4,552
Lượt bình luận
0
Rating
0.00 star(s) 0 đánh giá

Share this media

Back
Bên trên Bottom