posted 17 years ago
Unless this is a possible answer, I think there is a bug in the following code sample:
void start() {
InnerRun ir = new InnerRun();
Thread t = new Thread(ir); //wasn't passed the runnable ir
InnerRunTwo irr = new InnerRunTwo(t);
Thread uu = new Thread(irr);
t.start();
uu.start();
}
If you make this change then you will get 100 Ren and then 100 Stimpy. As it was in the original code, the thead t wasn't given a job(a runnable) to do.