Generic Types and Methods
- slide 10 : 21
Constraints: Strings of comparable elements
String<T>
generalizes
string of char
to
string of comparable elements
The generic interface IComparable<T>
The generic class
String<T>
.
Illustrating a number of
String<int>
objects.
Output from the
String<int>
program.
Illustrating Strings of different types.
Output from the String of different types program.
Comparable Pairs