Question: Can you answer this question for me please in java languages Q1: Write a java program that create and initialize one dimensional array of 20
Can you answer this question for me please in java languages

Q1: Write a java program that create and initialize one dimensional array of 20 integers then do the following: a. Fill the array with random numbers (0-50). b. Print out (display) these 20 random numbers. c. Print out (display) all the numbers which are divisible by 4. d. Print out (display) a counter that will show how many numbers is divisible by 4. e. Find the total and average of all elements in the array. f. Find large and smallest element in the array. Sample Output: The Random numbers are : 2 26 49 11 12 36 50 23 35 36 23 50 11 3 22 41 2 24 27 23 The numbers divisable by 4 are : 12 36 36 24 Count of numbers = 4 The total of all numbers is: 506 The avrage of all numbers is: 25 The Largest number of all numbers is: 50 The Smallest number of all numbers is: 2
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
