Generation

generate functionThu, 26 Jan 2023

Write main method in Solution class. In the main method read five values for an integer array and two int value which are the limits (limit1 and limit2). The main method should print the average of integer than Values which are greater than limit1 limit2. For example if the values are 1,2,3,4,5 and the limits are 2 and 6 then the average is 4((3+4+5)/3). The output should be in the format of sample output. Note: The returned average value should be of int data Sample code snippet for reference. Please use below code to build your solution public class Solution { public static void main(String[] args) //code to read String[] args) { //code to o display the result } Instruction: Kindly mention class name as MyClass

public static void main(String[] args) //code to read String[] args) { //code to o display the result }

Questions about programming?Chat with your personal AI assistant