import java.util.*;
import java.io.*;

public class Parser
{
    public static final String DELIMITER = ",";
    public static final String PRODUCES = "=>";
    public static final String SPACE = " ";

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

    public void loadData (String fileName)
    {
        /*
         * Open the data file and read it in.
         */

        BufferedReader reader = null;
        String[] values = null;

        try
        {
            reader = new BufferedReader(new FileReader(fileName));
            String line = null;

            while ((line = reader.readLine()) != null)
            {
                //values = line.split(Intcode.DELIMITER);

                /*
                 * Line format:
                 * 
                 * - ALWAYS start with a number
                 * - ALWAYS follow with a String
                 * - Then EITHER a comma if more than one chemical OR => to denote end of reactants
                 * - ALWAYS end in a number and a String
                 */
            }
        }
        catch (Throwable ex)
        {
            ex.printStackTrace();
        }
        finally
        {
            try
            {
                reader.close();
            }
            catch (Throwable ex)
            {
            }
        }
    }

    private boolean _debug;
}
@@ -78,22 +78,20 @@
 c final 
-String
+char
  DELIMIT
@@ -99,11 +99,11 @@
 R = 
-%22,%22
+','
 ;%0A  
@@ -172,22 +172,20 @@
 c final 
-String
+char
  SPACE =
@@ -189,11 +189,11 @@
 E = 
-%22 %22
+' '
 ;%0A%0A 
@@ -647,67 +647,8 @@
   %7B%0A
-                //values = line.split(Intcode.DELIMITER);%0A%0A
     
@@ -960,32 +960,32 @@
 er and a String%0A
-
                 
@@ -987,16 +987,195 @@
       */
+%0A%0A                 int quantitySpace = line.indexOf(SPACE);%0A                 int quantity = Integer.parseInt(line.substring(0, quantitySpace));%0A                 %0A                 
 %0A       

Update Parser.java