unctions specified in the SimpleArrayList interface. Make sure the class that implements SimpleArrayList is named "StudentArrayList" or else the test code will not compile. All of the documentation for the function guidelines may be found in the interface. This assignment can be a lot of programming if you do not follow the DRY (Don't Repeat Yourself) programming principle. Though it may look like a lot of work, in reality, it is much less because many methods depend on each other. If you make sure you call other smaller methods in the larger methods you will save your self a lot of time.   You are not allowed to use any 3rd party data structures or libraries such as or anything in the Java.Utils package. Submit the file named StudentArrayList.java to Grad

Microsoft Visual C#
7th Edition
ISBN:9781337102100
Author:Joyce, Farrell.
Publisher:Joyce, Farrell.
Chapter9: Using Classes And Objects
Section: Chapter Questions
Problem 9E
icon
Related questions
Question

Java programming 

Create a file named StudentArrayList.java, within the file create a class named StudentArrayList. This class is meant to mimic the ArrayList data structure. It will hold an ordered list of items. This list should have a variable size, meaning an arbitrary number of items may be added to the list. Most importantly this class should implement the interface SimpleArrayList provided. Feel free to add as many other functions and methods as needed to your class to accomplish this task. In other words, the class StudentArrayList must implement the interface SimpleArrayList. You have to write the code for each of the functions specified in the SimpleArrayList interface. Make sure the class that implements SimpleArrayList is named "StudentArrayList" or else the test code will not compile.

All of the documentation for the function guidelines may be found in the interface. This assignment can be a lot of programming if you do not follow the DRY (Don't Repeat Yourself) programming principle. Though it may look like a lot of work, in reality, it is much less because many methods depend on each other. If you make sure you call other smaller methods in the larger methods you will save your self a lot of time.  

You are not allowed to use any 3rd party data structures or libraries such as or anything in the Java.Utils package.

Submit the file named StudentArrayList.java to Grader Than for grading.

Hints:

  • Make an object array (Object[]) as a field. Use the array to store elements added to the class. If an item is removed from the StudentArrayList all items to the right of the item that is removed must be shifted over one place to the left. When the array reaches capacity, you must augment the size of the object array by creating a larger empty array and copying elements from the old array into the new array. 
  • Use .equals() to test the equality of elements in the Object array.
  • The size() function should return the total number of added items to the class not the total capacity of the internal array.
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
Passing Array as Argument
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Microsoft Visual C#
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,