Added 2B
This commit is contained in:
BIN
RunnableTest.class
Normal file
BIN
RunnableTest.class
Normal file
Binary file not shown.
16
RunnableTest.java
Normal file
16
RunnableTest.java
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
class x implements Runnable {
|
||||||
|
public void run(){
|
||||||
|
for(int i=0; i<=5; i++){
|
||||||
|
System.out.println("The Thread x is: "+i);
|
||||||
|
}
|
||||||
|
System.err.println("End of the Thread x");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
class RunnableTest {
|
||||||
|
public static void main(String[] args) {
|
||||||
|
x r = new x();
|
||||||
|
Thread threadx = new Thread(r);
|
||||||
|
threadx.start();
|
||||||
|
System.out.println("The end of the main thread");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Before Width: | Height: | Size: 7.9 KiB After Width: | Height: | Size: 7.9 KiB |
BIN
src/2B.png
Normal file
BIN
src/2B.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 19 KiB |
Reference in New Issue
Block a user