Program: 10226
Project: 10226
Buggy source:
public void start(){
  allowedMisclassifications=(int)Math.round(noise * nrOfExamples);
  if (startDescription == null) {
    startNode=new ExampleBasedNode(Thing.instance);
    startNode.setCoveredExamples(learningProblem.getPositiveExamples(),learningProblem.getNegativeExamples());
  }
 else {
    startNode=new ExampleBasedNode(startDescription);
    Set<Individual> coveredNegatives=rs.instanceCheck(startDescription,learningProblem.getNegativeExamples());
    Set<Individual> coveredPositives=rs.instanceCheck(startDescription,learningProblem.getPositiveExamples());
    startNode.setCoveredExamples(coveredPositives,coveredNegatives);
  }
  candidates.add(startNode);
  candidatesStable.add(startNode);
  ExampleBasedNode bestNode=startNode;
  int loop=0;
  algorithmStartTime=System.nanoTime();
  long lastPrintTime=0;
  long lastTreeTraversalTime=System.nanoTime();
  long lastReductionTime=System.nanoTime();
  long traversalInterval=1000l * 1000000000l;
  long reductionInterval=300l * 1000000000l;
  long currentTime;
  while (!solutionFound && !stop) {
    currentTime=System.nanoTime();
    if (currentTime - lastPrintTime > 1000000000) {
      printStatistics(false);
      lastPrintTime=currentTime;
      logger.debug("String_Node_Str" + loop + "String_Node_Str");
    }
    if (useTreeTraversal && (currentTime - lastTreeTraversalTime > traversalInterval)) {
      traverseTree();
      lastTreeTraversalTime=System.nanoTime();
    }
    if (useCandidateReduction && (currentTime - lastReductionTime > reductionInterval)) {
      reduceCandidates();
      lastReductionTime=System.nanoTime();
    }
    System.out.println("String_Node_Str" + candidates.last().getShortDescription(nrOfPositiveExamples,nrOfNegativeExamples,baseURI));
    bestNode=candidates.last();
    newCandidates.clear();
    candidates.remove(bestNode);
    extendNodeProper(bestNode,bestNode.getHorizontalExpansion() + 1);
    candidates.add(bestNode);
    candidates.addAll(newCandidates);
    candidatesStable.addAll(newCandidates);
    if (writeSearchTree) {
      String treeString="String_Node_Str" + bestNode + "String_Node_Str";
      if (expandedNodes.size() > 1) {
        treeString+="String_Node_Str";
        for (        ExampleBasedNode n : expandedNodes) {
          treeString+="String_Node_Str" + n + "String_Node_Str";
        }
      }
      expandedNodes.clear();
      treeString+=startNode.getTreeString(nrOfPositiveExamples,nrOfNegativeExamples,baseURI);
      treeString+="String_Node_Str";
      if (replaceSearchTree)       Files.createFile(searchTreeFile,treeString);
 else       Files.appendFile(searchTreeFile,treeString);
    }
    loop++;
  }
  if (solutionFound) {
    logger.info("String_Node_Str" + candidatesStable.last().getShortDescription(nrOfPositiveExamples,nrOfNegativeExamples,baseURI));
    logger.info("String_Node_Str");
    for (    Description c : solutions) {
      logger.info("String_Node_Str" + c + "String_Node_Str"+ c.getLength()+ "String_Node_Str"+ c.getDepth()+ "String_Node_Str");
    }
  }
  logger.debug("String_Node_Str" + candidates.size());
  printStatistics(true);
  if (stop)   logger.info("String_Node_Str");
 else   logger.info("String_Node_Str");
}

Fixed version (ground truth):
public void start(){
  allowedMisclassifications=(int)Math.round(noise * nrOfExamples);
  if (startDescription == null) {
    startNode=new ExampleBasedNode(Thing.instance);
    startNode.setCoveredExamples(learningProblem.getPositiveExamples(),learningProblem.getNegativeExamples());
  }
 else {
    startNode=new ExampleBasedNode(startDescription);
    Set<Individual> coveredNegatives=rs.instanceCheck(startDescription,learningProblem.getNegativeExamples());
    Set<Individual> coveredPositives=rs.instanceCheck(startDescription,learningProblem.getPositiveExamples());
    startNode.setCoveredExamples(coveredPositives,coveredNegatives);
  }
  candidates.add(startNode);
  candidatesStable.add(startNode);
  ExampleBasedNode bestNode=startNode;
  int loop=0;
  algorithmStartTime=System.nanoTime();
  long lastPrintTime=0;
  long lastTreeTraversalTime=System.nanoTime();
  long lastReductionTime=System.nanoTime();
  long traversalInterval=1000l * 1000000000l;
  long reductionInterval=300l * 1000000000l;
  long currentTime;
  while (!solutionFound && !stop) {
    currentTime=System.nanoTime();
    if (currentTime - lastPrintTime > 3000000000l) {
      printStatistics(false);
      lastPrintTime=currentTime;
      logger.debug("String_Node_Str" + loop + "String_Node_Str");
    }
    if (useTreeTraversal && (currentTime - lastTreeTraversalTime > traversalInterval)) {
      traverseTree();
      lastTreeTraversalTime=System.nanoTime();
    }
    if (useCandidateReduction && (currentTime - lastReductionTime > reductionInterval)) {
      reduceCandidates();
      lastReductionTime=System.nanoTime();
    }
    bestNode=candidates.last();
    newCandidates.clear();
    candidates.remove(bestNode);
    extendNodeProper(bestNode,bestNode.getHorizontalExpansion() + 1);
    candidates.add(bestNode);
    candidates.addAll(newCandidates);
    candidatesStable.addAll(newCandidates);
    if (writeSearchTree) {
      String treeString="String_Node_Str" + bestNode + "String_Node_Str";
      if (expandedNodes.size() > 1) {
        treeString+="String_Node_Str";
        for (        ExampleBasedNode n : expandedNodes) {
          treeString+="String_Node_Str" + n + "String_Node_Str";
        }
      }
      expandedNodes.clear();
      treeString+=startNode.getTreeString(nrOfPositiveExamples,nrOfNegativeExamples,baseURI);
      treeString+="String_Node_Str";
      if (replaceSearchTree)       Files.createFile(searchTreeFile,treeString);
 else       Files.appendFile(searchTreeFile,treeString);
    }
    loop++;
  }
  if (solutionFound) {
    logger.info("String_Node_Str" + candidatesStable.last().getShortDescription(nrOfPositiveExamples,nrOfNegativeExamples,baseURI));
    logger.info("String_Node_Str");
    for (    Description c : solutions) {
      logger.info("String_Node_Str" + c + "String_Node_Str"+ c.getLength()+ "String_Node_Str"+ c.getDepth()+ "String_Node_Str");
    }
  }
  logger.debug("String_Node_Str" + candidates.size());
  printStatistics(true);
  if (stop)   logger.info("String_Node_Str");
 else   logger.info("String_Node_Str");
}