Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.util.Scanner;
- import static java.lang.Math.*;
- public class Main {
- public static void main(String[] args) {
- Scanner sc = new Scanner(System.in);
- int n = sc.nextInt(), ans = 0;
- for (int i = 0; i < n; i++)
- {
- int r = sc.nextInt();
- ans += r % 5 == 0 && r % 7 != 0 ? 1 : 0;
- }
- System.out.println(ans > 0 ? "YES" : "NO");
- }
- }
Add Comment
Please, Sign In to add comment