Question: 1. Create a Java class called Array Product that calculates the product of the values of two integer arrays of the same length using their

1. Create a Java class called Array Product that calculates the product of the values of two integer arrays of the same length using their relative position Get the array size from the user. The size must be in the range of 5 to 20 (both inclusive) Include the following methods: a. createArray(): This method must be called twice from main. The array size must be passed in as a parameter. The return value is the integer array created. This method will use a loop to input values in the array. Each iteration of the loop will have the user's input value being assigned to the current index position. The input values can be any integer. b. calculateProduct(): this will have two arrays passed in as parameters and the product displayed. See example below. Example: size of arrays: 5 array_1 created from user input: 1, 2, 3, 4, 5 array_2 created from user input: 5, 4, 3, 2, 1 Product of both arrays: 5, 8, 9, 8, 5 The number at the same index position in both arrays will be multiplied to get the product. This will only

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!