code: private String removeCommentsFromInput(BufferedReader in) throws IOException {
  	  String l = in.readLine();
  	  //remove lines that start with a comment
  	  while(l.startsWith("#")){
  	    l = in.readLine();
  	  }
  	  if(l.contains("#")){
  	    l = l.substring(0, l.indexOf("#"));
  	  }
  	  return l.trim();
    }
docs: Takes the input stream and ignores lines starting with a # and everything after a #