-
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathFun3.java
More file actions
19 lines (17 loc) · 605 Bytes
/
Fun3.java
File metadata and controls
19 lines (17 loc) · 605 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
package funsimple;
public class Fun3 {
public static void main(String[] args) {
MEAN(3,4,5,6);
MEAN(6,7,8,9);
MEAN(6,7,8,9);
MEAN(4,5,9,2);
}
public static void MEAN(int a, int b, int c, int d) {
int ab = (a + b) / 2;
int ac = (a + c) / 2;
int ad = (a + d) / 2;
System.out.printf("%d va %d juftlikning O`rta arifmetiki: %d \n", a, b, ab);
System.out.printf("%d va %d juftlikning O`rta arifmetiki: %d \n", a, c, ac);
System.out.printf("%d va %d juftlikning O` rta arifmetiki: %d \n", a, d, ad);
}
}