import java.util.*; import java.io.*; public class Certificate { private int noCars; // number of cars private int noOpt; // number of options private int noClass; // number of classes private int[] p; // number of cars with option i in a block private int[] q; // size of a block for option i private int[] demand; // demand for class i, i.e. number of cars of class i private int[][] option; // option[i][j] = 1 <-> class i requires option j private int[] optDemand; // demand for an option private int[] posn; // position, the class of car in this slot private int[][] posnOpt; // actual options taken at given positions public Certificate(String fname1,String fname2) throws Exception { MyIo fin1 = new MyIo(fname1); // read in the problem noCars = fin1.getNextInt(); noOpt = fin1.getNextInt(); noClass = fin1.getNextInt(); p = new int[noOpt]; q = new int[noOpt]; demand = new int[noClass]; option = new int[noClass][noOpt]; optDemand = new int[noOpt]; posn = new int[noCars]; posnOpt = new int[noCars][noOpt]; for (int i=0;i