/* Parameterized types can be bounded, that is, we can require that the concrete class
    that will replace the parameterized type have certain properties, like extend a
    particular class or implement an interface.

    Parameterized types can be bounded by at most one superclass and by any number of interfaces.
    We use & to separate the list of classes and interfaces that the parameterized type is bounded by.

   This example shows we can also have multiple parameterized types (E and T).
*/

import java.io.Serializable;

class Map<E,T extends Number & Serializable & Comparable<T>> {

	E elm1 = null;
	T elm2 = null;

	Map(E arg1, T arg2) {
		elm1 = arg1;
		elm2 = arg2;
	}

	@Override
	public String toString() {
		return "(" + elm1 + "," + elm2 + ")";
	}
}
