import structure5.*; class Example { /** * Adds one to the given input. * @param x An integer. * @pre x must be an integer less than MAX_VALUE. * @post return value is greater than input. * @return x plus one. */ public static int addOne(int x) { Assert.pre(x < Integer.MAX_VALUE, "x must be an integer less than MAX_VALUE"); int z = x + 1; Assert.post(z > x, "z must be greater than x."); return z; } public static void main(String[] args) { int x = Integer.valueOf(args[0]); int z = addOne(x); System.out.println(z); } }