package com.lainxi2; public class ceshi3 extends Thread{ public void run() { dxc(); } public void dxcf() { for(int i = 0;i< 10;i++) { System.out.println(this + " 啦啦啦德玛西亚 "); try { Thread.sleep(100); } catch (InterruptedException e) { // TODO 自动生成的 catch 块 e.printStackTrace(); } } } public class ceshi2 { public static void main(String[] args) throws InterruptedException { ceshi3 cs = new ceshi3(); cs.start(); ceshi3 cs1 = new ceshi3(); cs1.start();
时间: 2024-10-09 00:57:40