package com.javarush.task.task06.task0616;

/*
Минимальное число статиков
*/

public class Solution {
    public static int step;     // здесь

    public static void main(String[] args) {
        method1();
    }

    public static void method1() {  // здесь
        method2();
    }

    public static void method2() {    // здесь
        new Solution().method3();
    }

    public void method3() {
        method4();
    }

    public void method4() {
        step++;
        for (StackTraceElement element : Thread.currentThread().getStackTrace())
            System.out.println(element);
        if (step > 1)
            return;
        main(null);
    }
}