Pi rewritten in Java.