cours0708/G5a/Puissance4/test/Principale.java

52 lines
967 B
Java

package test;
import java.util.*;
public class Principale {
private Vector l1 = new Vector(6);
private Vector l2 = new Vector(6);
private Vector l3 = new Vector(6);
private Vector l4 = new Vector(6);
private Vector l5 = new Vector(6);
private Vector l6 = new Vector(6);
private Vector l7 = new Vector(6);
private void afficheJeu()
{
System.out.print(l7+"\n");
System.out.print(l6+"\n");
System.out.print(l5+"\n");
System.out.print(l4+"\n");
System.out.print(l3+"\n");
System.out.print(l2+"\n");
System.out.print(l1);
}
private void initJeu()
{
for(int i=0; i<14; i++) //14 car caractere codé sur 2 octets
{
l1.add("1");
l2.add("2");
l3.add("3");
l4.add("4");
l5.add("5");
l6.add("6");
l7.add("7");
i++;
}
l1.set(3, "X");
}
public static void main(String[] args){
Principale p4 = new Principale();
p4.initJeu();
p4.afficheJeu();
}
}