import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);
int[] A = new int[10];
int count = 0;
boolean b;
for(int i = 0; i < A.length; i++) {
A[i] = sc.nextInt() % 42;
}
for(int i = 0; i < A.length; i++) {
b = false;
for(int j = i+1; j < A.length; j++) {
if(A[i] == A[j]) {
b = true;
break;
}
}
if(b == false)
count++;
}
System.out.println(count);
sc.close();
}
}
'Algorithm > Baekjoon' 카테고리의 다른 글
[백준_JAVA] 10811 바구니 뒤집기 (0) | 2023.08.11 |
---|---|
[백준_JAVA] 1546 평균 (0) | 2023.08.10 |
[백준_JAVA] 1085 직사각형에서 탈출 (0) | 2023.08.08 |
[백준_JAVA] 5086 배수와 약수 (0) | 2023.08.07 |
[백준_JAVA] 5597 과제 안 내신 분..? (0) | 2023.08.05 |