public static void yield(){
  try {
    sleep(1);
  }
 catch (  InterruptedException i) {
  }
}

public static void yield ( ) { try { sleep ( 1 ) ; } catch ( InterruptedException i ) { } }
causes the currently executing thread object to temporarily pause and allow other threads to execute .
