Skip to content
Snippets Groups Projects
Commit 8dcfa02f authored by Patrick Dowler's avatar Patrick Dowler
Browse files

fixed output of numeric arrays to be space-separated

parent 569fcea5
No related branches found
No related tags found
No related merge requests found
......@@ -113,23 +113,23 @@ public class IntArrayFormatter implements Formatter
private String toString(int[] iarray)
{
StringBuffer sb = new StringBuffer();
StringBuilder sb = new StringBuilder();
for (int i : iarray)
{
sb.append(Integer.toString(i));
sb.append(",");
sb.append(" ");
}
return sb.substring(0, sb.length() - 1); // trim trailing comma
return sb.substring(0, sb.length() - 1); // trim trailing space
}
private String toString(Integer[] iarray)
{
StringBuffer sb = new StringBuffer();
StringBuilder sb = new StringBuilder();
for (Integer i : iarray)
{
sb.append(i.toString());
sb.append(",");
sb.append(" ");
}
return sb.substring(0, sb.length() - 1); // trim trailing comma
return sb.substring(0, sb.length() - 1); // trim trailing space
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment