I have a question and needs an expert advice on this.
I have a main Method and i creates two child threads from there. Now my child threads are running and main thread has finished execution, is there is any possibility for my program to hang because of this reason.
I always had very clear concept that the child thread can run even after the main thread has finished running. but today i read in complete reference that
"in a multi-threaded program, the main thread must be the last
thread to finish running. If the main thread finishes before a child thread has completed,
then the Java run-time system may "hang"