// Alphabet.java import java.util.Enumeration; import java.util.Vector; public class Alphabet { private Vector alphabet; private int card; Alphabet() { this.alphabet = new Vector(); this.alphabet.addElement(new Lettre('a')); this.alphabet.addElement(new Lettre('b')); this.alphabet.addElement(new Lettre('c')); this.alphabet.addElement(new Lettre('d')); this.card = 4; } public int getCard() { return this.card; } public Enumeration elements() { return this.alphabet.elements(); } public int rang(Lettre a) { for (int i = 0; i < this.alphabet.size(); ++i) if (a.equals((Lettre)alphabet.elementAt(i))) return(i); return(-1); } }