Example #1
0
 public static void main(String[] args) throws Exception {
   for (int i = 0; i < 10; i++) {
     Thread daemon = new Thread(new SimpleDaemons());
     daemon.setDaemon(true); // Must call before start()
     daemon.start();
   }
   print("All daemons started");
   TimeUnit.MILLISECONDS.sleep(175);
 }