code: public static String printLong(long l) {
  		if (l >= 0) return "" + ((l == APSPSolver.INF ? "INF" : l));
  		return "" + (-l == APSPSolver.INF ? "-INF" : l);
  	}
docs: Class method for pretty-printing longs (substitutes +/-INF appropriately).
  @param l The long value to pretty-print.
  @return a String representation of the given long value.