MathWorks Interview Question

Find the output or trouble-shoot this snippet of Java/C++ code.