#Whitespace
You should have whitespace around your operators:
xcoord=avenue;
for(int i=0;i<count;i++)
#Magic Numbers
In your code, magic numbers are numbers that are unexplained and simply left as is:
public void turnLeft()
{
turnLeft(1);
}
public void turnRight()
{
turnLeft(3);
}
public void turnAround()
{
turnLeft(2);
}
You should move these magic numbers to another variable, so their purpose is more easily understandable.
#turnLeft
:
This variable name could probably use better terminology than that.
#goTo
:
You will incur the wrath of many programmers using this a method name, use a different name like jumpToCoordinate
#cases:
You should be using camelcase for variable names:
int xdiff=xdest-xcoord;
int ydiff=ydest-ycoord;
Not to mention they could use a refactor, it's a few chararacters for readability and maintainability:
xDifference
, xDestination
, xCoordinate
, see? much better