Removed System.exit() from Java example programs
removed System.exit() calls in Scala example programs