代做Assignment 1 Assignment on Generic Data Structures in Java代写Java编程
- 首页 >> WebAssignment 1
Title: Assignment on Generic Data Structures in Java
Objective:
This assignment aims to assess yourunderstanding ofgeneric data structures in Java.You will be required to implement a generic data structure and demonstrate itsusagethrough Java code.
Instructions:
Part 1: Implementing a Generic Data Structure
1. Choose one of the following generic data structures to implement:
-Generic Stack
-Generic Queue
-Generic LinkedList
2. Implement the chosen data structure using Java generics.Ensure that the data structure can store elements of any data type.
3. Include essential operations for the chosen data structure. For example:
-For a Generic Stack:push,pop,peek,isEmpty
-For a Generic Queue:enqueue,dequeue,isEmpty
-For a Generic LinkedList:add,remove,get,size
4. Implementappropriate error-handling mechanisms where needed,such as handling empty data structures or invalid operations
Part 2: Demonstration of Usage
1. Create a Java class that demonstrates the usage of the generic data structure you implemented in Part 1.
2. Show how to create an instance of the data structure and add,remove,or manipulate elements
3. Include examples that showcase the flexibility of generic data structures by using differentdata types (e.g.integers, strings,custom objects).
4. Ensure that the demonstration is well-commented and easy to follow.
Part 3: Submission
1. Organize your code into a well-structured Java project.
2. Provide cleardocumentation,including comments explaining the purpose and usage of classes,methods,and variables.
3. Submit your assignment as an MS Word fle containing the entire project,includingthe source code and any necessary documentation.Plus,Screenshot of your output.
Evaluation Criteria:
Your assignment will be evaluated based on the following criteria:
1. Correctness of the implemented generic data structure.
2. Proper usage ofJava generics.
3. Demonstration of usage with clear and well-commented code.
4. Adequate error handling and boundary case consideration.
5. Code organization and documentation quality.