import java.util.*;

public class Verifier
{
    public static final String EXAMPLE1_DATA = "example1.txt";
    public static final int EXAMPLE1_DIFFERENCE1 = 7;
    public static final int EXAMPLE1_DIFFERENCE2 = 0;
    public static final int EXAMPLE1_DIFFERENCE3 = 5;

    public static final String EXAMPLE2_DATA = "example2.txt";

    public Verifier (boolean debug)
    {
        _debug = debug;
    }

    public boolean verify ()
    {
        Vector<JoltageAdapter> adapters = Util.loadData(EXAMPLE1_DATA, _debug);
        Device device = Util.largest(adapters, _debug);
        Connector con = new Connector(_debug);
        Vector<JoltageAdapter> sorted = con.connect(adapters);

        sorted.add(device.getAdapter());

        for (int i = 0; i < sorted.size(); i++)
        {
            System.out.println("Adapter: "+sorted.elementAt(i).outputJoltage());
        }

        con.getDifferenceThree().add(device.getAdapter());

        if (con.getDifferenceOne().size() == EXAMPLE1_DIFFERENCE1)
        {
            if (con.getDifferenceTwo().size() == EXAMPLE1_DIFFERENCE2)
            {
                if (con.getDifferenceThree().size() == EXAMPLE1_DIFFERENCE3)
                {
                    return true;
                }
                else
                    System.out.println("Wrong difference 3 for "+EXAMPLE1_DATA+": "+con.getDifferenceThree().size());
            }
            else
                System.out.println("Wrong difference 2 for "+EXAMPLE1_DATA+": "+con.getDifferenceTwo().size());
        }
        else
            System.out.println("Wrong difference 1 for "+EXAMPLE1_DATA+": "+con.getDifferenceOne().size());

        return false;
    }

    private boolean _debug;
}
@@ -331,109 +331,605 @@
 t%22;%0A
-%0A    public Verifier (boolean debug)%0A    %7B%0A        _debug = debug;%0A    %7D%0A%0A    public boolean verify (
+    public static final int EXAMPLE2_DIFFERENCE1 = 22;%0A    public static final int EXAMPLE2_DIFFERENCE2 = 0;%0A    public static final int EXAMPLE2_DIFFERENCE3 = 10;%0A%0A    public Verifier (boolean debug)%0A    %7B%0A        _debug = debug;%0A    %7D%0A%0A    public boolean verify ()%0A    %7B%0A        if (check(EXAMPLE1_DATA, EXAMPLE1_DIFFERENCE1, EXAMPLE1_DIFFERENCE2, EXAMPLE1_DIFFERENCE3))%0A            return check(EXAMPLE2_DATA, EXAMPLE2_DIFFERENCE1, EXAMPLE2_DIFFERENCE2, EXAMPLE2_DIFFERENCE3);%0A        else%0A            return false;%0A    %7D%0A%0A    private boolean check (String file, int diff1, int diff2, int diff3
 )%0A  
@@ -988,29 +988,20 @@
 oadData(
-EXAMPLE1_DATA
+file
 , _debug
@@ -1467,35 +1467,20 @@
 ze() == 
-EXAMPLE1_DIFFERENCE
+diff
 1)%0A     
@@ -1533,35 +1533,20 @@
 ze() == 
-EXAMPLE1_DIFFERENCE
+diff
 2)%0A     
@@ -1609,36 +1609,21 @@
 ze() == 
-EXAMPLE1_DIFFERENCE3
+diff1
 )%0A      
@@ -1767,37 +1767,28 @@
 nce 3 for %22+
-EXAMPLE1_DATA
+file
 +%22: %22+con.ge
@@ -1903,37 +1903,28 @@
 nce 2 for %22+
-EXAMPLE1_DATA
+file
 +%22: %22+con.ge
@@ -2029,29 +2029,20 @@
 1 for %22+
-EXAMPLE1_DATA
+file
 +%22: %22+co

Update Verifier.java