답안 #126509

# 제출 시각 아이디 문제 언어 결과 실행 시간 메모리
126509 2019-07-08T02:12:04 Z briansu Broken Device (JOI17_broken_device) C++14
45 / 100
73 ms 3312 KB
#include "Annalib.h"
#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
#define REP(i, n) for(int i = 0;i < n;i ++)

void Anna( int N, long long X, int K, int P[] ){
  vector<ll> v(N, 1);
  REP(i, K)v[P[i]] = 0;
  ll ct = 0, tt = 0;
  vector<ll> d(N, 0);
  REP(i, N)
  {
  	if(ct == 60)d[i] = 0;
  	else if(!v[i])tt++, d[i] = 0;
  	else if((tt&1) != (X&1))d[i] = 0, tt++;
  	else d[i] = 1, tt = 0, X /= 2, ct ++;
  }
  REP(i, N)Set(i, d[i]);
}
#include "Brunolib.h"
#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
#define REP(i, n) for(int i = 0;i < n;i ++)

long long Bruno( int N, int A[] ){
  ll n = N;
  ll tt = 0, t = 1, fg = 0;
  REP(i, n)
  {
  	if(!A[i])fg = !fg;
  	else tt += t * fg, t *= 2, fg = 0;
  }
  return tt;
}
# 결과 실행 시간 메모리 Grader output
1 Partially correct 41 ms 3056 KB Output is partially correct - L* = 31
2 Partially correct 40 ms 3056 KB Output is partially correct - L* = 17
3 Partially correct 41 ms 3056 KB Output is partially correct - L* = 24
4 Partially correct 40 ms 2904 KB Output is partially correct - L* = 18
5 Partially correct 40 ms 3056 KB Output is partially correct - L* = 25
6 Partially correct 40 ms 3064 KB Output is partially correct - L* = 17
7 Partially correct 40 ms 3056 KB Output is partially correct - L* = 23
8 Partially correct 40 ms 3056 KB Output is partially correct - L* = 30
9 Partially correct 40 ms 3056 KB Output is partially correct - L* = 29
10 Partially correct 40 ms 3056 KB Output is partially correct - L* = 31
11 Partially correct 40 ms 3056 KB Output is partially correct - L* = 20
12 Partially correct 40 ms 3056 KB Output is partially correct - L* = 21
13 Partially correct 41 ms 3056 KB Output is partially correct - L* = 28
14 Partially correct 40 ms 3064 KB Output is partially correct - L* = 19
15 Partially correct 73 ms 3056 KB Output is partially correct - L* = 26
16 Partially correct 41 ms 3056 KB Output is partially correct - L* = 18
17 Partially correct 45 ms 3056 KB Output is partially correct - L* = 17
18 Partially correct 40 ms 3064 KB Output is partially correct - L* = 30
19 Partially correct 40 ms 3056 KB Output is partially correct - L* = 29
20 Partially correct 40 ms 3024 KB Output is partially correct - L* = 21
21 Partially correct 40 ms 3056 KB Output is partially correct - L* = 29
22 Partially correct 40 ms 3056 KB Output is partially correct - L* = 25
23 Partially correct 40 ms 3056 KB Output is partially correct - L* = 26
24 Partially correct 43 ms 3056 KB Output is partially correct - L* = 22
25 Partially correct 43 ms 3056 KB Output is partially correct - L* = 27
26 Partially correct 41 ms 3056 KB Output is partially correct - L* = 23
27 Partially correct 41 ms 3056 KB Output is partially correct - L* = 29
28 Partially correct 41 ms 3312 KB Output is partially correct - L* = 23
29 Partially correct 40 ms 3056 KB Output is partially correct - L* = 27
30 Partially correct 40 ms 3056 KB Output is partially correct - L* = 28
31 Partially correct 40 ms 3056 KB Output is partially correct - L* = 32
32 Partially correct 40 ms 3056 KB Output is partially correct - L* = 27
33 Partially correct 40 ms 3056 KB Output is partially correct - L* = 18
34 Partially correct 40 ms 3056 KB Output is partially correct - L* = 30
35 Partially correct 40 ms 3056 KB Output is partially correct - L* = 26
36 Partially correct 40 ms 3056 KB Output is partially correct - L* = 20
37 Partially correct 40 ms 3056 KB Output is partially correct - L* = 20
38 Partially correct 40 ms 2904 KB Output is partially correct - L* = 29
39 Partially correct 40 ms 3056 KB Output is partially correct - L* = 26
40 Partially correct 40 ms 3152 KB Output is partially correct - L* = 29