What is currentThread()?
Question : What is currentThread()?
It is a public static method used to obtain a reference to the current thread.
It is a public static method used to obtain a reference to the current thread.