Mine works but I put it on the inside::

if (another.equals("y"))
{
if (rand == num) //Numbers match, WIN

System.out.println("You guessed RIGHT ... you WIN!!!");

else //Numbers don't match LOSE

System.out.println("You guessed WRONG ... TRY AGAIN >>>");

// Here's where you ask to play again

System.out.print("Try Again . . . y/n?? ");
another = Keyboard.readString();