线程优先级-------setPriority( )设置优先级

代码: package cn.tedu.thread; public class PriorityDemo { public static void main(String[] args) { //创建线程对象 Thread t1=new Thread(new PDemo(),“A”); Thread t2=new Thread(new PDemo(),“B”); //设置优先级 t1.setPr
相关文章
相关标签/搜索