src/Operator.java
/*
   * To avoid interleaving printing to the output between the various threads.
   */
To avoid interleaving printing to the output between the various threads.
To avoid interleaving printing to the output between the various threads .
synchronized static void appendToOutput(String s, boolean lineBreak) {
  	if (lineBreak)
  		Operator.output += s + "\n";
  	else
  		Operator.output += s;
  }
synchronized static void appendToOutput ( String s , boolean lineBreak ) { if ( lineBreak ) Operator . output += s + "\n" ; else Operator . output += s ; }
To avoid interleaving printing to the output between the various threads.
To avoid interleaving printing to the output between the various threads .