I don't know whether I should ask this question here or in some other forum. One day me and my friend were thinking as to whether there is any way we can have the loop effect(doing things continously till a point) without using loops. One solution we came up with was the use of goto but that's not won't do the trick incase of java. Other solution that we thought was using recursive methods. I wonder is there any other way to achieve the same result. The method need not be efficent. But no importing of any classes is allowed except those implictly imported. Or would importing classes really make any difference if the imported classes also don't use loops for doing things repeatedly. The use of native methods is also not allowed. I guess that may also work. I am not sure about it never used them fully. Please do also comment whether importing classes make any difference and using native methods. [ June 27, 2003: Message edited by: Anupam Sinha ]
With lambda calculus you can do anything a Turing machine can even though there's no concept of a loop. Unfortunately it can cause your brain to hurt at times. I'm not sure what it would take to simulate lambda calculus in Java (perhaps just some really clever use of anonymous inner classes?).
Joined: Jan 30, 2002
Here's a perverse little class that will do the HelloWorld100 deal. I'm not sure if anyone posted something similar. NoLoopLooper.java