Please answer my question need help.getting error recompile with xlint. Java uses or overrides deprecated API. This is the third time am trying to post this question and still not able to post if this question get posted this time please answer my question
class a extends Thread {
public void run() {
for(int i=1;i<=5;i++) {
if(i==1) {
yield();
}
System.out.println("message from a "+i);
}
System.out.println("exit from a");
}
}
class b extends Thread {
public void run() {
for(int i=1;i<=5;i++) {
System.out.println("message from b "+i);
if(i==3)
stop();
}
System.out.println("exit from b");
}
}
class c extends Thread {
public void run () {
for(int i=1;i<=5;i++) {
System.out.println("message from c" +i);
if(i==1)
try {
sleep(1001);
}
catch(Exception e) {
}
}
System.out.println("exit from c");
}
}
class threadsmethods {
public static void main(String args []) {
System.out.println("started Thread a");
new a().start();
System.out.println("Thread b started");
new b().start();
System.out.println("Thread c started");
new c().start();
System.out.println("end of main Thread");
}
}