@@ -0,0 +1,1186 @@
+/*%0A * Code used in the %22Software Engineering%22 course.%0A *%0A * Copyright 2017 by Claudio Cusano (claudio.cusano@unipv.it)%0A * Dept of Electrical, Computer and Biomedical Engineering,%0A * University of Pavia.%0A */%0A%0A/*%0A * Matricola: 427263%0A*/%0A%0Apackage goldrush;%0A%0Aimport java.util.Random;%0A%0A/**%0A *%0A * @author cl427263%0A */%0Apublic class Euge extends GoldDigger %7B%0A    int chosenSite;%0A    int tmpchs;%0A    Euge()%0A    %7B%0A        %0A    %7D%0A    %0A    public void basicChoice(int%5B%5D distances)%0A    %7B%0A        Random rr = new Random();%0A            tmpchs = rr.nextInt(distances.length);%0A        %0A        for(int i = 0; i %3C distances.length; i++)%0A        %7B%0A            if(tmpchs == distances%5Bi%5D)%0A            %7B%0A                %0A                chosenSite = i;%0A            %7D%0A        %7D%0A    %7D%0A    %0A    @Override%0A    public int chooseDiggingSite(int%5B%5D distances)%0A    %7B%0A        basicChoice(distances);%0A        return chosenSite;%0A    %7D%0A    %0A    %0A    @Override%0A    public void dailyOutcome(int revenue, int%5B%5D distances, int%5B%5D diggers)%0A    %7B%0A        %0A       %0A        %0A        while(revenue %3C 8)%0A        %7B%0A            %0A            %0A            chooseDiggingSite(distances);%0A            %0A        %7D%0A        %0A    %7D%0A    %0A    %0A%7D%0A

Test #1