Computer Science, asked by mithuashu181622, 5 hours ago

write a program to find average of five numbers using non-static method ​

Answers

Answered by shivansh223101
0

Answer:

impot java.util.Scanner;

class average

{

static void main()

{

Scanner s= new Scanner(System.in);

int a,b,c,d,e,f;

System.out.println("Enter the numbers");

a=s.nextInt();

b=s.nextInt();

c=s.nextInt();

d=s.nextInt();

e=s.nextInt();

System.out.println((a+b+c+d+e)/5);

}

}

Similar questions