Post after long time


/ Published in: Java
Save to your folder(s)



Copy this code and paste it in your HTML
  1. private boolean buildExpressionWithRestOfTheValues(int item, StringBuffer expression, int expectedTotal, ArrayList restOfValues, String operator) {
  2. StringBuffer newExpression = new StringBuffer();
  3. boolean isPossibleWithRestOfValues = find(restOfValues, expectedTotal, newExpression);
  4. if(isPossibleWithRestOfValues){
  5. expression.append("(").append(newExpression).append(operator).append(item).append(")");
  6. return true;
  7. }
  8. return false;
  9. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.