3435363738394041424344
* The main thread also tries to get the lock */ boolean value; do { try { value=lock.tryLock(1,TimeUnit.SECONDS); if (!value) { System.out.printf("Main: Trying to get the Lock\n"); } } catch (InterruptedException e) { e.printStackTrace();