First Problem:

g.drawString(String, x, y);


Second:

Create two random objects (possibly just one) and an array of crab objects:

Code:
Crab[] c = new Crab[5];
for (int index=0; index<c.length; ++c)
{
   c = new Crab(randomx.nextInt(), randomy.nextInt());
}
That's not everything, but it should get you started.