class KW extends Thread { public void run() { System.out.println("Thread Running..."); } public static void main(String args[]) { KW k=new KW(); k.start(); } }
kodingwindow@kw:~$ javac KW.javakodingwindow@kw:~$ java KW Thread Running... kodingwindow@kw:~$