classMyRunnableimplementsRunnable{@Overridepublicvoidrun(){System.out.println("子线程");}}publicclassTestRunnable{publicstaticvoidmain(String[]args){MyRunnablemr=newMyRunnable();Threadt1=newThread(mr);t1.start();System.out.println("main");}}