-
-
Notifications
You must be signed in to change notification settings - Fork 109
Expand file tree
/
Copy pathComparetheTriplets.java
More file actions
32 lines (30 loc) · 697 Bytes
/
Copy pathComparetheTriplets.java
File metadata and controls
32 lines (30 loc) · 697 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
import java.io.*;
import java.util.*;
import java.text.*;
import java.math.*;
import java.util.regex.*;
public class Solution {
public static void main(String[] args) {
Scanner in = new Scanner(System.in);
int a0 = in.nextInt();
int a1 = in.nextInt();
int a2 = in.nextInt();
int b0 = in.nextInt();
int b1 = in.nextInt();
int b2 = in.nextInt();
int a=0,b=0;
if(a0>b0)
a++;
else if(a0<b0)
b++;
if(a1>b1)
a++;
else if(a1<b1)
b++;
if(a2>b2)
a++;
else if(a2<b2)
b++;
System.out.println(a+" "+b);
}
}