Share
Explore BrainMass

Criticism-remarks on the enclosed java code

The enclosed Java code was suppose to address the following problem, where I require in giving comments/criticism/remarks if possible with respect to the Java coding standards.
Problem Details: Write a Java program which defines two unconstrained arrays of user defined length n, that contain n Random numbers each and which outputs the addition of pairs of elements. For example, given {1, 2, 3} and {4, 5, 6} the output would be {5, 7, 9}.

Attachments

Solution Preview

The attached code files attempts to solve the problem of creating two unconstrained arrays where the length of the arrays is given by the user at runtime.

In general it is a good software programming practice to follow variable naming conventions. For example, include abbreviated form of variable type as prefix. intArray gives a lot
more information than Array. It is also a good documenting habit to include input(s), output(s) and ...

$2.19