Submission #10137622


Source Code Expand

Copy
#include <iostream>
#include <vector>
using namespace std;

int main() {
  int n;
  cin >> n;
  bool good = true;
  for (int i = 0; i < n; i++) {
    int a;
    cin >> a;
    if (a % 2 == 0) {
      if (!(a % 3 == 0 || a % 5 == 0)) {
        good = false; break;
      }
    }
  }
  if (good) {
    cout << "APPROVED";
  }
  else {
    cout << "DENIED";
  }
}

Submission Info

Submission Time
Task B - Papers, Please
User Ununus
Language C++14 (GCC 5.4.1)
Score 200
Code Size 382 Byte
Status AC
Exec Time 1 ms
Memory 256 KB

Judge Result

Set Name Sample Subtask1
Score / Max Score 0 / 0 200 / 200
Status
AC × 2
AC × 20
Set Name Test Cases
Sample sample_01.txt, sample_02.txt
Subtask1 sample_01.txt, sample_02.txt, sub1_01.txt, sub1_02.txt, sub1_03.txt, sub1_04.txt, sub1_05.txt, sub1_06.txt, sub1_07.txt, sub1_08.txt, sub1_09.txt, sub1_10.txt, sub1_11.txt, sub1_12.txt, sub1_13.txt, sub1_14.txt, sub1_15.txt, sub1_16.txt, sub1_17.txt, sub1_18.txt
Case Name Status Exec Time Memory
sample_01.txt AC 1 ms 256 KB
sample_02.txt AC 1 ms 256 KB
sub1_01.txt AC 1 ms 256 KB
sub1_02.txt AC 1 ms 256 KB
sub1_03.txt AC 1 ms 256 KB
sub1_04.txt AC 1 ms 256 KB
sub1_05.txt AC 1 ms 256 KB
sub1_06.txt AC 1 ms 256 KB
sub1_07.txt AC 1 ms 256 KB
sub1_08.txt AC 1 ms 256 KB
sub1_09.txt AC 1 ms 256 KB
sub1_10.txt AC 1 ms 256 KB
sub1_11.txt AC 1 ms 256 KB
sub1_12.txt AC 1 ms 256 KB
sub1_13.txt AC 1 ms 256 KB
sub1_14.txt AC 1 ms 256 KB
sub1_15.txt AC 1 ms 256 KB
sub1_16.txt AC 1 ms 256 KB
sub1_17.txt AC 1 ms 256 KB
sub1_18.txt AC 1 ms 256 KB