编程练习
来源:3-6 自由编程
一娆Hacker
2020-12-22 09:23:04
Letter
package com.lding.thread;
public class Letter implements Runnable{
@Override
public void run() {
for(int i=0;i<26;i++){
System.out.print((char)('a'+i));
try {
Thread.sleep(1000);
} catch (InterruptedException e) {
e.printStackTrace();
}
}
}
}
LetterTest
package com.lding.thread;
public class LetterTest {
public static void main(String[] args) {
Letter one= new Letter();
Thread mt=new Thread(one);
mt.start();
}
}
1回答
好帮手慕小班
2020-12-22
同学你好,同学已完成练习,棒棒哒!继续加油!
祝学习愉快
相似问题