// Collection of code snippets by Arne Vajhøj 
// (likely posted to comp.os.vms/INFO-VAX, INFO-TPU, MACRO32, eksperten.dk, newz.dk, LinkedIn or other place sometime between 1990 and now) 
public class LocalFunction {
    public static void test() {
        class LF {
            public void p(int n, String s) {
                for(int i = 0; i < n; i++) {
                    System.out.println(s);
                }
            }
        }
        LF o = new LF();
        o.p(1, "One");
        o.p(2, "Two");
    }
    public static void main(String[] args) {
        test();
    }
}
