Java Puzzle 9: Tweet

Feb 02, 2015

Short but challenging, a puzzle that fits in a tweet, exploring the power a superclass has over its subclass:


  1. Copy-paste that code unchanged into
  2. Write anything you want in
  3. Execute it with java A. The security manager is there to avoid you cheat too much.
  4. If it reaches the statement that prints "Win" in B, then you won.
  5. Post your solution as a comment here below. The comments will not be visible yet, to give everyone a chance to solve it without seeing the solution. Compare your answer to the solution