C# - C Sharp: Practical 2: Products Management System


Khóa học qua video:
Lập trình Python All Lập trình C# All SQL Server All Lập trình C All Java PHP HTML5-CSS3-JavaScript
Đăng ký Hội viên
Tất cả các video dành cho hội viên

PRODUCTS MANAGEMENT SYSTEM

1. Create class Product with some properties and methods:

· string Name

· string Description

· double Price //0 < Price <= 100

· int[ ] rate //store points which users vote the product, 1 - 5

· void ViewInfo() // display name, price and description about the product

2. Create class Shop with some properties and methods:

· ArrayList ProductList //store list of products in the shop

· void  AddProduct()  //ask user entering information about new product and add the product to ProductList

· void RemoveProduct() //ask user entering a product name and delete the product

· void IterateProductList() //iterate the Product List, call ViewInfo() of a Product, calculate average point of Product and display the information to screen.

· void SearchProduct() //ask user entering 2 numbers, after that search and display information of products that their prices between them.

3. Create a menu:

PRODUCT MANAGEMENT SYSTEM

  1. Add new product
  2. Remove product
  3. Iterate product list
  4. Search product
  5. Exit

And implement the methods in class Shop to menu.

Extra:

Add a method called SortProduct to class Shop that can sort products in product list by their prices.

» Tiếp: Practical 3: Zoo Management System
« Trước: Practical 1
Khóa học qua video:
Lập trình Python All Lập trình C# All SQL Server All Lập trình C All Java PHP HTML5-CSS3-JavaScript
Đăng ký Hội viên
Tất cả các video dành cho hội viên
Copied !!!