Skip to content

Latest commit

 

History

History

week4

Generic Types & Generic Vectors

Generic Types

This is one very important concept in Java - the ability to give the user the ability (and power) to determine the type that he wants to keep inside the data structure.

The best way to get a graps of generic types is to read the following documentation: https://docs.oracle.com/javase/tutorial/java/generics/types.html

Generic Vector

Here is an implementation of a generic Vector in Java.

Problems to solve

There are plenty of problems, waiting for you to solve them, using the knowledge about the vector data structure.

Once we have implemented it ourselves, we can use java.util.Vector - a generic Vector class, from the Java standard library.

The probmes are: