Here's the relevant code:
public static void printBoarders (Territory x)
{
int t = 0 ;
int n = 0 ;
for (int i = 0; i<x.borders.length; i++)
{
if (x.borders[i] == -1)
t = i ;
}
for (int j = 0; j<x.borders.length; j++)
{
if (x.borders[j] == 1)
n++ ;
}
Territory.translate (t) ;
System.out.print (" has " + n + " borders: ") ;
Territory.translate (x.borders) ;
System.out.println (" ") ;
}
When I run this, I get everything on one line without a line break. Why isn't the System.out.println (" ") ;
creating a line break?
Here is an example of what the output winds up being:
Northwest Territory, Alberta, Kamchatka, hidavid-names-macbook-pro:~ davidname$
EDIT: the problem was that this method was never being invoked. A different one which i was replacing was. All is well.