Integer vs int
Write a program that creates two arrays, int[ ] x and Integer[ ] y , each of size 1,000,000. Initialize each array separately so that x[k] k and y[k] references an Integer object containing k . Time each segment separately and report your results. Do the experiment again but initialize x[k] and y[k] to 1, for all k . Explain your results.
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here