Newer
Older
package p4a;
import java.util.Random;
public class MainLinkedListPersoGet {
public static void main(String[] args) {
Random rnd = new Random();
LinkedListPerso<Integer> linkedList = new LinkedListPerso<Integer>();
int nbOperation = Integer.parseInt(args[0]);
for (int i = 0; i < nbOperation; i++) {
linkedList.ajout(0, i);
}
for (int i = 0; i < nbOperation; i++) {
linkedList.acces(rnd.nextInt(nbOperation));
}
}
}