Question: Exercise 22: Void Methods Folder name A170 E22 YourLastName Your FirstName For this exercise, you will implement four (4) void methods using the void methods

 Exercise 22: Void Methods Folder name A170 E22 YourLastName Your FirstName
For this exercise, you will implement four (4) void methods using the

Exercise 22: Void Methods Folder name A170 E22 YourLastName Your FirstName For this exercise, you will implement four (4) void methods using the void methods project. The project contains three (3) arrays already declared and initialized. You need to implement the following methods in the sections indicated by the comments: Method print o Parameter: An array of integers and number of elements. o Prints out all the elements of the array on the same line and separated by a space. o See format in the sampleoutput shown below. Method printLargest o Parameter: An array of integers and number of elements. o Use a FOR loop to find the largest element in the array o Call the method print to print out the entire array. Print the largest element as shown in the sample output. Method printAllEvens o Parameter: An array of integers and number of elements. o Call the method print to print out the entire array. o Use a FOR loop to print out all the even numbers in the array. Numbers should be on the same line and separated by a space. o See format in the sample output shown below. Method printsum o Parameter: An array of integers and number of elements. o Call the method print to print out the entire array. o Use a FOR loop to calculate the sum of all numbers in the array. o output the final result in the format shown in the sample output below Method search o Parameters: An array of integers, the number of elements, and an integer to search for. o Call the method print to print out the entire array. o Use a WHILE loop to find the element. o The while loop should STOP when the element is found or when the search has reached the end of the array. output the final resultin the format shown in the sample output below. The method main has comments to guide you in implementing the function calls. In the main method: Do NOT add any additional System.out print statements. Do NOT add any additional code other than the function calls that are specified in the comments. (See next page for sample output)

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!