Please add the following code to complete the output requirements.
import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner in = new Scanner(System.in);
int a,b,c,d,e;
a = in.nextInt();
b = in.nextInt();
c = in.nextInt();
d = in.nextInt();
e = in.nextInt();
RR rr = new RR();
double dd = rr.fun(a,b,c,d,e);
System.out.printf("%.2f",dd);
}
}
class RR{
}
Input format:
Provide 5 positive integers not exceeding 1000 in one line.
Output format:
output the average value of 5 integers, with two decimal places reserved.
Input example:
1 2 3 4 5
Sample output:
3.00
class RR{
public double fun(int a,int b,int c,int d,int e){
return (a+b+c+d+e)/5;
}
}