Click here to watch in Youtube :
Click the below Image to Enlarge
![]() |
| Java Tutorial : Java Threads (Java multithreading Introduction) |
![]() |
| Java Tutorial : Java Threads (Java multithreading Introduction) |
public class MainThread
{
public static void main(String[] args)
{
Thread thread = Thread.currentThread();
thread.setName("MainThread");
System.out.println("Name of thread = " + thread);
}
}
Name of thread = Thread[MainThread,5,main]
Click the below link to download the code:


No comments:
Post a Comment