JetSynthesys Interview Question

Core Java, programming puzzles. Based on string manipulation.