
what is ment by daemon

Java Daemon Threads
Daemon threads are like a service providers for other threads or objects running in the same process as the daemon thread. Daemon threads are used for background supporting tasks and are only needed while normal threads are executing.
For more information, Visit Here

yes we can achieve the same functionality by writing static block because static block executes first before the main function we use this when we need to write two main functions in the same program
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.