日期:2014-05-20 浏览次数:20982 次
public class HelloWorld { public static void main(String[] args) { try { if (new RuntimeException() { boolean n() { switch (getStackTrace().length) { case 3: return false; case 4: return true; default: printStackTrace(); throw this; } } public void printStackTrace() { main(null); }; }.n()) { System.out.print("Hello "); } else { System.out.println("world!"); } } catch (Exception e) { e.printStackTrace(); } } }
------解决方案--------------------
确实有点无聊了
------解决方案--------------------
果然够无聊