public class Euler394 {
    private static double expectedSteps(double x) {
        return 7.0 / 9.0 + (2.0 / 3.0) * Math.log(x) + 2.0 / (9.0 * x * x * x);
    }

    public static String solve() {
        return String.format("%.10f", expectedSteps(40.0)).replace(',', '.');
    }

    public static void main(String[] args) {
        System.out.println(solve());
    }
}
