QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#79808 | #5523. Graph Problem With Small $n$ | rin204 | WA | 1100ms | 101436kb | C++17 | 6.5kb | 2023-02-20 21:58:39 | 2023-02-20 21:58:42 |
Judging History
answer
// #pragma GCC target("avx2")
// #pragma GCC optimize("O3")
// #pragma GCC optimize("unroll-loops")
#include<bits/stdc++.h>
using namespace std;
using ll = long long;
using ull = unsigned long long;
template <class T>
using pq = priority_queue<T>;
template <class T>
using qp = priority_queue<T, vector<T>, greater<T>>;
#define vec(T, A, ...) vector<T> A(__VA_ARGS__);
#define vvec(T, A, h, ...) vector<vector<T>> A(h, vector<T>(__VA_ARGS__));
#define vvvec(T, A, h1, h2, ...) vector<vector<vector<T>>> A(h1, vector<vector<T>>(h2, vector<T>(__VA_ARGS__)));
#ifndef RIN__LOCAL
#define endl "\n"
#endif
#define spa ' '
#define len(A) A.size()
#define all(A) begin(A), end(A)
#define fori1(a) for(ll _ = 0; _ < (a); _++)
#define fori2(i, a) for(ll i = 0; i < (a); i++)
#define fori3(i, a, b) for(ll i = (a); i < (b); i++)
#define fori4(i, a, b, c) for(ll i = (a); ((c) > 0 || i > (b)) && ((c) < 0 || i < (b)); i += (c))
#define overload4(a, b, c, d, e, ...) e
#define fori(...) overload4(__VA_ARGS__, fori4, fori3, fori2, fori1)(__VA_ARGS__)
template <typename T>
vector<tuple<ll, T>> ENUMERATE(vector<T> &A, ll s = 0){
vector<tuple<ll, T>> ret(A.size());
for(int i = 0; i < A.size(); i++) ret[i] = {i + s, A[i]};
return ret;
}
vector<tuple<ll, char>> ENUMERATE(string &A, ll s = 0){
vector<tuple<ll, char>> ret(A.size());
for(int i = 0; i < A.size(); i++) ret[i] = {i + s, A[i]};
return ret;
}
#define enum1(A) fori(A.size())
#define enum2(a, A) for(auto a:A)
#define enum3(i, a, A) for(auto&& [i, a]: ENUMERATE(A))
#define enum4(i, a, A, s) for(auto&& [i, a]: ENUMERATE(A, s))
#define enum(...) overload4(__VA_ARGS__, enum4, enum3, enum2, enum1)(__VA_ARGS__)
template <typename T, typename S>
vector<tuple<T, S>> ZIP(vector<T> &A, vector<S> &B){
int n = min(A.size(), B.size());
vector<tuple<T, S>> ret(n);
for(int i = 0; i < n; i++) ret[i] = {A[i], B[i]};
return ret;
}
template <typename T, typename S>
vector<tuple<ll, T, S>> ENUMZIP(vector<T> &A, vector<S> &B, ll s = 0){
int n = min(A.size(), B.size());
vector<tuple<ll, T, S>> ret(n);
for(int i = 0; i < n; i++) ret[i] = {i + s, A[i], B[i]};
return ret;
}
#define zip4(a, b, A, B) for(auto&& [a, b]: ZIP(A, B))
#define enumzip5(i, a, b, A, B) for(auto&& [i, a, b]: ENUMZIP(A, B))
#define enumzip6(i, a, b, A, B, s) for(auto&& [i, a, b]: ENUMZIP(A, B, s))
#define overload6(a, b, c, d, e, f, g, ...) g
#define zip(...) overload6(__VA_ARGS__, enumzip6, enumzip5, zip4, _, _, _)(__VA_ARGS__)
vector<char> stoc(string &S){
int n = S.size();
vector<char> ret(n);
for(int i = 0; i < n; i++) ret[i] = S[i];
return ret;
}
#define INT(...) int __VA_ARGS__; inp(__VA_ARGS__);
#define LL(...) ll __VA_ARGS__; inp(__VA_ARGS__);
#define STRING(...) string __VA_ARGS__; inp(__VA_ARGS__);
#define CHAR(...) char __VA_ARGS__; inp(__VA_ARGS__);
#define VEC(T, A, n) vector<T> A(n); inp(A);
#define VVEC(T, A, n, m) vector<vector<T>> A(n, vector<T>(m)); inp(A);
const ll MOD1 = 1000000007;
const ll MOD9 = 998244353;
template<class T> auto min(const T& a){
return *min_element(all(a));
}
template<class T> auto max(const T& a){
return *max_element(all(a));
}
template <class T, class S>
inline bool chmax(T &a, const S &b) {
return (a < b ? a = b, 1 : 0);
}
template <class T, class S>
inline bool chmin(T &a, const S &b) {
return (a > b ? a = b, 1 : 0);
}
void FLUSH(){cout << flush;}
void print(){cout << endl;}
template <class Head, class... Tail>
void print(Head &&head, Tail &&... tail) {
cout << head;
if (sizeof...(Tail)) cout << spa;
print(forward<Tail>(tail)...);
}
template<typename T>
void print(vector<T> &A){
int n = A.size();
for(int i = 0; i < n; i++){
cout << A[i];
if(i == n - 1) cout << endl;
else cout << spa;
}
}
template<typename T>
void print(vector<vector<T>> &A){
for(auto &row: A) print(row);
}
template<typename T, typename S>
void print(pair<T, S> &A){
cout << A.first << spa << A.second << endl;
}
template<typename T, typename S>
void print(vector<pair<T, S>> &A){
for(auto &row: A) print(row);
}
template<typename T, typename S>
void prisep(vector<T> &A, S sep){
int n = A.size();
for(int i = 0; i < n; i++){
cout << A[i];
if(i == n - 1) cout << endl;
else cout << sep;
}
}
template<typename T, typename S>
void priend(T A, S end){
cout << A << end;
}
template<typename T>
void priend(T A){
priend(A, spa);
}
template<class... T>
void inp(T&... a){
(cin >> ... >> a);
}
template<typename T>
void inp(vector<T> &A){
for(auto &a:A) cin >> a;
}
template<typename T>
void inp(vector<vector<T>> &A){
for(auto &row:A) inp(row);
}
template<typename T, typename S>
void inp(pair<T, S> &A){
inp(A.first, A.second);
}
template<typename T, typename S>
void inp(vector<pair<T, S>> &A){
for(auto &row: A) inp(row.first, row.second);
}
template<typename T>
T sum(vector<T> &A){
T tot = 0;
for(auto a:A) tot += a;
return tot;
}
template<typename T>
pair<vector<T>, map<T, int>> compression(vector<T> X){
sort(all(X));
X.erase(unique(all(X)), X.end());
map<T, int> mp;
for(int i = 0; i < X.size(); i++) mp[X[i]] = i;
return {X, mp};
}
void solve(){
INT(n);
VVEC(char, S, n, n);
vec(int, edges, 1 << n, 0);
fori(i, n) fori(j, n){
if(S[i][j] == '1') edges[1 << i] |= 1 << j;
}
fori(i, n){
fori(bit, 1 << n){
if((bit >> i) & 1) edges[bit] |= edges[bit ^ (1 << i)];
}
}
vec(int, dp, 1 << (n - 1), 0);
fori(j, n - 1){
if(S[n - 1][j] == '1') dp[1 << j] = 1 << j;
}
fori(bit, 1 << (n - 1)){
if(dp[bit] == 0) continue;
fori(j, n - 1){
if(!((bit >> j) & 1) && ((edges[dp[bit]] >> j) & 1)) dp[bit | (1 << j)] |= 1 << j;
}
}
vec(int, ok, n, 0);
int mask = (1 << (n - 1)) - 1;
ok[n - 1] = dp[mask];
fori(i, n - 1){
if((dp[mask] >> i) & 1) dp[i] |= 1 << (n - 1);
}
fori(bit, 1 << (n - 1)){
fori(i, (n - 1)){
if(dp[bit] >> i & 1) ok[i] |= dp[bit ^ mask];
}
}
vvec(int, ans, n, n, 0);
fori(i, n) fori(j, n){
if((ok[i] >> j) & 1) ans[i][j] = 1;
}
for(auto row:ans) prisep(row, "");
}
int main(){
cin.tie(0)->sync_with_stdio(0);
// cout << fixed << setprecision(12);
int t;
t = 1;
// cin >> t;
while(t--) solve();
return 0;
}
詳細信息
Test #1:
score: 100
Accepted
time: 0ms
memory: 3384kb
input:
4 0110 1010 1101 0010
output:
0001 0001 0000 1100
result:
ok 4 lines
Test #2:
score: 0
Accepted
time: 2ms
memory: 3388kb
input:
6 010001 101000 010100 001010 000101 100010
output:
010001 101000 010100 001010 000101 100010
result:
ok 6 lines
Test #3:
score: 0
Accepted
time: 2ms
memory: 3360kb
input:
4 0111 1011 1101 1110
output:
0111 1011 1101 1110
result:
ok 4 lines
Test #4:
score: 0
Accepted
time: 181ms
memory: 52164kb
input:
23 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 000000000...
output:
00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 000000000000...
result:
ok 23 lines
Test #5:
score: 0
Accepted
time: 184ms
memory: 52196kb
input:
23 00010100000000000101000 00000000010000000001000 00000000000001000000001 10000000000000000010000 00000000000000000000000 10000000000000000000000 00000001000000000000000 00000010000000000010000 00000000000001000000000 01000000000000000000000 00000000000000000000000 00000000000000000000000 000000000...
output:
00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 000000000000...
result:
ok 23 lines
Test #6:
score: 0
Accepted
time: 179ms
memory: 52228kb
input:
23 00001000000000000000000 00001000010001000000000 00000000000101000010000 00001000000100000000000 11010000010011000100000 00000000000100000000000 00000000000000000000001 00000000000000000101000 00000000000000000000000 01001000000000101010010 00000000000000000000101 00110100000010001000000 000010000...
output:
00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 000000000000...
result:
ok 23 lines
Test #7:
score: 0
Accepted
time: 203ms
memory: 52292kb
input:
23 01000000000001101001100 10000001101000000000000 00000100000100010000100 00000000000000001011000 00000100001000000000000 00101000000000001000001 00000000000000000000000 01000000000000000000000 01000000000100000010000 00000000000001000000011 01001000000000010000000 00100000100001000100001 000000000...
output:
00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 00000000000000000000000 000000000000...
result:
ok 23 lines
Test #8:
score: 0
Accepted
time: 234ms
memory: 52168kb
input:
23 00000000010001001001010 00100010001101110000001 01000001000100110000000 00000011010001101100100 00000000010000010001000 00000000000000001001000 01010001000000000000001 00110010000000000000010 00000000011000100100000 10011000101000100000000 01000000110010101010000 01100000000000000000000 000000000...
output:
01111111110111110110111 10011111110111110110111 10011111110111110110111 11101111110110110110111 11110111110111110110111 11111011110111111111111 11111101110111110110111 11111110110111110110111 11111111010111110110111 11111111100110100110111 00000000000010000010100 11111111110011110110111 111111111111...
result:
ok 23 lines
Test #9:
score: 0
Accepted
time: 264ms
memory: 52052kb
input:
23 00001000001001000000000 00101100111110100000000 01001000100001011010000 00000000010000010010000 11100001100001000000010 01000010101010100011011 00000100000100100010000 00001000011000000010001 01101100000000011001001 01010001000010011000000 11000101000110001100000 01000010001000000000010 010001000...
output:
00000000000000000000100 00000000000000000000100 00000000000000000000100 00000000000000000000100 00000000000000000000100 00000000000000000000100 00000000000000000000100 00000000000000000000100 00000000000000000000100 00000000000000000000100 00000000000000000000100 00000000000000000000100 000000000000...
result:
ok 23 lines
Test #10:
score: 0
Accepted
time: 316ms
memory: 52196kb
input:
23 00001011110010000000001 00000100000011000000100 00010011010100000000011 00100011011001010100100 10000101000110100000000 01001000001010001000100 10110000000110000010000 10111000001100010100010 10000000000010001000110 10110000001110100110001 00010101010100001000000 00101011011000100100011 110011101...
output:
00000000000000000001000 00000000000000000001000 00000000000000000001000 00000000000000000001000 00000000000000000001000 00000000000000000001000 00000000000000000001000 00000000000000000001000 00000000000000000001000 00000000000000000001000 00000000000000000001000 00000000000000000001000 000000000000...
result:
ok 23 lines
Test #11:
score: 0
Accepted
time: 376ms
memory: 52060kb
input:
23 00100100001000000100001 00101110110000100100001 11000000000101001000100 00000000010000001111010 01000011010001011001010 11000000010100001001011 01001000001010101000100 00001000001010000000000 01000000000001100001011 01011100001101100000000 10000011010010100000010 00100100010000000001000 000000110...
output:
01111111111111111111111 10111111111111111111111 11011111111111111111111 11101111111111111111111 11110111111111111111111 11111011111111111111111 11111101111111111111111 11111110111111111111111 11111111011111111111111 11111111101111111111111 11111111110111111111111 11111111111011111111111 111111111111...
result:
ok 23 lines
Test #12:
score: 0
Accepted
time: 459ms
memory: 52048kb
input:
23 00000001011001011100100 00000001010000000010100 00000001010010100010000 00001000100111100000000 00010100011000010111001 00001000100001000010010 00000001111001100011000 11100010111100110001001 00010111010000101100110 11101011100000100100100 10001011000010100000010 00010001000001011101110 001100000...
output:
01111111111111111111111 10111111111111111111111 11011111111111111111111 11101111111111111111111 11110111111111111111111 11111011111111111111111 11111101111111111111111 11111110111111111111111 11111111011111111111111 11111111101111111111111 11111111110111111111111 11111111111011111111111 111111111111...
result:
ok 23 lines
Test #13:
score: 0
Accepted
time: 441ms
memory: 52196kb
input:
23 00100100001101000100000 00010111011000100000010 10000010010001111000010 01001011101001000100000 00010000010110000100111 11000000101000011101001 01110001100000010101100 01010010001001010100000 00010110001100010010001 01101000000011000111000 11010101100010010001101 10001000100010001110100 000010000...
output:
01111111111111111111111 10111111111111111111111 11011111111111111111111 11101111111111111111111 11110111111111111111111 11111011111111111111111 11111101111111111111111 11111110111111111111111 11111111011111111111111 11111111101111111111111 11111111110111111111111 11111111111011111111111 111111111111...
result:
ok 23 lines
Test #14:
score: 0
Accepted
time: 520ms
memory: 52200kb
input:
23 01001101001011010101100 10001010111100100001110 00000000010101000111100 00000000001010010100010 11000000100110000111000 10000010001000010101000 01000100100010001100101 10000000010001000110110 01001010000001111100000 01100001000001001101001 11010100000011001010111 01101000000000100100110 100110100...
output:
01111111111111111111111 10111111111111111111111 11011111111111111111111 11101111111111111111111 11110111111111111111111 11111011111111111111111 11111101111111111111111 11111110111111111111111 11111111011111111111111 11111111101111111111111 11111111110111111111111 11111111111011111111111 111111111111...
result:
ok 23 lines
Test #15:
score: 0
Accepted
time: 509ms
memory: 52232kb
input:
23 01100101000101001000001 10111000100000010110010 11011010011101000010010 01100010001111011011111 01100010011110001111100 10000000011000001011010 00111001001000101100111 10000010110110011000000 01000001001110010100100 00101101000100111100001 00111110100110011011010 10111001111010001010000 000110011...
output:
01111111111111111111111 10111111111111111111111 11011111111111111111111 11101111111111111111111 11110111111111111111111 11111011111111111111111 11111101111111111111111 11111110111111111111111 11111111011111111111111 11111111101111111111111 11111111110111111111111 11111111111011111111111 111111111111...
result:
ok 23 lines
Test #16:
score: 0
Accepted
time: 496ms
memory: 52196kb
input:
23 01111001001110001000101 10000000000100111111110 10010101000110100100101 10101000001010010101001 10010010011110101101111 00100000101100011000000 00001000011000010001101 10100000010000000000100 00000100010110001111100 00001011100101010110111 10011110000000010101101 11101100110010010100000 101110001...
output:
01111111111111111111111 10111111111111111111111 11011111111111111111111 11101111111111111111111 11110111111111111111111 11111011111111111111111 11111101111111111111111 11111110111111111111111 11111111011111111111111 11111111101111111111111 11111111110111111111111 11111111111011111111111 111111111111...
result:
ok 23 lines
Test #17:
score: 0
Accepted
time: 512ms
memory: 52208kb
input:
23 01010000000100001110001 10000110010001110010100 00011000101111001010110 10101111011100101100111 00110011111111111011000 01010011100001111011011 01011100001111000011101 00011100001110111010010 00101100011101001000011 01011000100000000000010 00111011100001001000111 10111011100000110100001 001010110...
output:
01111111111111111111111 10111111111111111111111 11011111111111111111111 11101111111111111111111 11110111111111111111111 11111011111111111111111 11111101111111111111111 11111110111111111111111 11111111011111111111111 11111111101111111111111 11111111110111111111111 11111111111011111111111 111111111111...
result:
ok 23 lines
Test #18:
score: 0
Accepted
time: 526ms
memory: 52336kb
input:
23 00100101011111000101011 00100001000110000111101 11010000011110010110011 00101101110110000101110 00010101111001110101110 10011001111101010011101 00000000110011000000100 11011100110111001110110 00011111000000100110010 10111111000111101010010 10101100000111111010100 11110101011010101010010 111100110...
output:
01111111111111111111111 10111111111111111111111 11011111111111111111111 11101111111111111111111 11110111111111111111111 11111011111111111111111 11111101111111111111111 11111110111111111111111 11111111011111111111111 11111111101111111111111 11111111110111111111111 11111111111011111111111 111111111111...
result:
ok 23 lines
Test #19:
score: 0
Accepted
time: 561ms
memory: 52232kb
input:
23 00100001100011011101011 00111011101101101011001 11001101100100001000111 01001010110101101000010 01110011001111000101111 00100011100000111101010 01011100000110101001100 11101100010110110011000 11110100010010000011010 00010001101011011011011 01001000010001001011111 01111011000010101011101 100010111...
output:
01111111111111111111111 10111111111111111111111 11011111111111111111111 11101111111111111111111 11110111111111111111111 11111011111111111111111 11111101111111111111111 11111110111111111111111 11111111011111111111111 11111111101111111111111 11111111110111111111111 11111111111011111111111 111111111111...
result:
ok 23 lines
Test #20:
score: 0
Accepted
time: 386ms
memory: 101364kb
input:
24 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 0000000000000000000000...
output:
000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 ...
result:
ok 24 lines
Test #21:
score: 0
Accepted
time: 404ms
memory: 101376kb
input:
24 000000000000100000000000 000000000000000000001000 000000000000000001000000 000000100000000000000000 000000000000000000000001 000000000000000001000000 000100000000100100000000 000000000000000000000000 000000000000000000000000 000000000000010000000000 000000000000000000000000 0000000000000000010000...
output:
000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 ...
result:
ok 24 lines
Test #22:
score: 0
Accepted
time: 398ms
memory: 101400kb
input:
24 000000000010000010000000 000000010100100000010010 000010010000000000000000 000000010000000001000000 001000000000001000000000 000000000100101000000000 000000000000000000000000 011100000001000000000000 000000000010000000000000 010001000000000010100001 100000001000000101000000 0000000100000000100100...
output:
000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 ...
result:
ok 24 lines
Test #23:
score: 0
Accepted
time: 406ms
memory: 101304kb
input:
24 000001001001101000001101 000000000000011000100100 000000000000010000000000 000000010000000000000000 000000000000000000000000 100000010000000110000000 000000000001000000010000 000101000000000010000000 100000000001011100011100 000000000000000000100000 000000000000000010001000 1000001010001000000010...
output:
000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 ...
result:
ok 24 lines
Test #24:
score: 0
Accepted
time: 488ms
memory: 101436kb
input:
24 011010010001001000000011 100000000000000111000001 100110000100100100010001 001011000100001000110000 101101000000000111000010 000110110000010000010000 000001000000000000000000 100001000001100001000001 000000000001000000110011 001100000000010000001000 000000000000000100000000 1000000110000010000000...
output:
000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000000010000000000000 000000000000000000000000 000000000000000000000000 000000000000000000000000 000000100000000000000000 000000000000000000000000 ...
result:
ok 24 lines
Test #25:
score: 0
Accepted
time: 570ms
memory: 101300kb
input:
24 010001010000000000000100 101011011100001011001100 010101010010000100000000 001001101010000000110010 010000000000000000001010 111100000010001101000100 000100000000010000110000 111000000000000011000001 010100000010000000010100 010000000000000001000001 001101001001100110000001 0000000000100100001000...
output:
011111111111111111111111 101111111111111111111111 110111111111111111111111 111011111111111111111111 111101111111111111111111 111110111111111111111111 111111011111111111111111 111111101111111111111111 111111110111111111111111 111111111011111111111111 111111111101111110111111 111111111110111111111111 ...
result:
ok 24 lines
Test #26:
score: 0
Accepted
time: 873ms
memory: 101404kb
input:
24 010001000001001010000001 100001001110101011001010 000000011000010000000100 000000010000100001110101 000000011001000001100010 110000000000000000011000 000000001000000100011010 001110001010000001110001 011010110000010000001001 010000000000100111100101 010000010000001000000000 1000100000000100101110...
output:
011111111111111111111111 101111111111111111111111 110111111111111111111111 111011111111111111111111 111101111111111111111111 111110111111111111111111 111111011111111111111111 111111101111111111111111 111111110111111111111111 111111111011111111111111 111111111101111111111111 111111111110111111111111 ...
result:
ok 24 lines
Test #27:
score: 0
Accepted
time: 815ms
memory: 101320kb
input:
24 010000000000000010000000 100000111000100110000011 000000111110010111000000 000001100001010000001100 000000001000000000110100 000100000100000101101111 011100010111010000110100 011000100010100000100010 011010000011001110000001 001001100010001001000010 001000111100000000100000 0001001010001100001000...
output:
011111111111111111111111 101111111111111101111111 110111111111111111111111 111011111111111111111111 111101111111111111111111 111110111111111111111111 111111011111111111111111 111111101111111111111111 111111110111111111111111 111111111011111111111111 111111111101111111111111 111111111110111111111111 ...
result:
ok 24 lines
Test #28:
score: 0
Accepted
time: 835ms
memory: 101380kb
input:
24 000100000000010010100000 000000001101000010011011 000000000011000000010000 100010100000100000010000 000100000010110101100001 000000111010100000100101 000101000110000011000000 000001001100101010000011 010001010000000010000101 010000110001011001010000 001011100000010010000011 0110000001000101100101...
output:
011111111111111111111111 101111111111111111011111 110111111111111111111111 111011111111111111111111 111101111111111111111111 111110111111111111111111 111111011111111111111111 111111101111111111111111 111111110111111111111111 111111111011111111111111 111111111101111111111111 111111111110111111111111 ...
result:
ok 24 lines
Test #29:
score: 0
Accepted
time: 925ms
memory: 101328kb
input:
24 000000000010110010000001 001010001011101000000110 010001001110000000010000 000000100010000010011101 010001101010010011010100 001010000000011101000010 000110000100101011001111 000000001000110000100000 011010010110000000000000 001000101010001010000100 111110001100100010011101 0100000000001011100000...
output:
011111111111111111111111 101111111111111111111111 110111111111111111111111 111011111111111111111111 111101111111111111111111 111110111111111111111111 111111011111111111111111 111111101111111111111111 111111110111111111111111 111111111011111111111111 111111111101111111111111 111111111110111111111111 ...
result:
ok 24 lines
Test #30:
score: 0
Accepted
time: 1051ms
memory: 101288kb
input:
24 010001111000001000000110 100001111000000110010000 000011000101000101100100 000001111111000110100100 001000001010010000111000 111100100000000001110000 110101011101000000001101 110100101000001011000100 110110110011001000000000 001100100000000011011001 000110001000100101110111 0011001010000110110100...
output:
011111111111111111111111 101111111111111111111111 110111111111111111111111 111011111111111111111111 111101111111111111111111 111110111111111111111111 111111011111111111111111 111111101111111111111111 111111110111111111111111 111111111011111111111111 111111111101111111111111 111111111110111111111111 ...
result:
ok 24 lines
Test #31:
score: 0
Accepted
time: 1084ms
memory: 101340kb
input:
24 010000010100011100001111 101010011110111111001010 010101011011100101111100 001000110000100010011011 010000000001010100001011 001000100000011000111001 000101011011001000001100 111100100011010011010100 011000100001000001111111 110000000011110100100010 011000110101000100001000 0010101111101100010001...
output:
011111111111111111111111 101111111111111111111111 110111111111111111111111 111011111111111111111111 111101111111111111111111 111110111111111111111111 111111011111111111111111 111111101111111111111111 111111110111111111111111 111111111011111111111111 111111111101111111111111 111111111110111111111111 ...
result:
ok 24 lines
Test #32:
score: 0
Accepted
time: 1035ms
memory: 101404kb
input:
24 001011000000111000011011 000100110101100000000100 100001101100110011000010 010011011110101000000110 100101010000100001011110 101110111100100000011111 011001011000001001110011 010111100001110001000110 001101100001110001011011 011101000010010001000100 000100000100001010110110 0100000110000100100100...
output:
011111111111111111111111 101111111111111111111111 110111111111111111111111 111011111111111111111111 111101111111111111111111 111110111111111111111111 111111011111111111111111 111111101111111111111111 111111110111111111111111 111111111011111111111111 111111111101111111111111 111111111110111111111111 ...
result:
ok 24 lines
Test #33:
score: 0
Accepted
time: 1052ms
memory: 101400kb
input:
24 000010011100100010110100 001011100011110001101010 010001000110100000000111 000001101101011000000111 110000101111000010001111 011100000000011010011000 010110000011100001101010 100000001011101011011101 100110010101101010011010 101110001001010101100101 011010110000011111100000 0101101111000100011011...
output:
011111111111111111111111 101111111111111111111111 110111111111111111111111 111011111111111111111111 111101111111111111111111 111110111111111111111111 111111011111111111111111 111111101111111111111111 111111110111111111111111 111111111011111111111111 111111111101111111111111 111111111110111111111111 ...
result:
ok 24 lines
Test #34:
score: 0
Accepted
time: 1100ms
memory: 101376kb
input:
24 001101101101001010011100 000010000000011001010101 100011110111100001101011 100011100011110101101100 011100010010001110010110 101100111100000110101100 101101000101011000101101 001011001101010110010101 100001010101110001010110 101001111011110111000000 001110000100011000101101 1011001111001111100101...
output:
011111111111111111111111 101111111111111111111111 110111111111111111111111 111011111111111111111111 111101111111111111111111 111110111111111111111111 111111011111111111111111 111111101111111111111111 111111110111111111111111 111111111011111111111111 111111111101111111111111 111111111110111111111111 ...
result:
ok 24 lines
Test #35:
score: 0
Accepted
time: 1082ms
memory: 101316kb
input:
24 010010110101111110011001 101100001000000100001010 010010101100010111001100 010011001101001011100111 101100011111101011010101 000100010011010011101011 101000001111101010000101 100011001000011110000111 011110110010101000100011 101110100011000101001001 000011101101010110110100 1001111001101010010000...
output:
011111111111111111111111 101111111111111111111111 110111111111111111111111 111011111111111111111111 111101111111111111111111 111110111111111111111111 111111011111111111111111 111111101111111111111111 111111110111111111111111 111111111011111111111111 111111111101111111111111 111111111110111111111111 ...
result:
ok 24 lines
Test #36:
score: 0
Accepted
time: 354ms
memory: 52196kb
input:
23 01111101111011111111001 10111101111011111111111 11011101111011111111001 11101101111011111111001 11110111111111111111101 11111001111011111111001 00001000000100000000100 11111100111011111111001 11111101011011111111001 11111101101011111111001 11111101110011111111001 00001010000000000000100 111111011...
output:
01111111111111111111011 10110101111011111111011 11011111111111111111011 11101111111111111111011 10110111111111111111001 11111011111111111111011 10111101111111111111111 11111110111111111111011 11111111011111111111011 11111111101111111111011 11111111110111111111011 10111111111011111111111 111111111111...
result:
ok 23 lines
Test #37:
score: 0
Accepted
time: 287ms
memory: 52328kb
input:
23 00100000001010010010110 00011111110111101101001 10000000000010000010110 01001111110111101101001 01010111110111101101001 01011011110111101101001 01011101110111101101001 01011110110111101101001 01011111010111101101001 01011111100111111101001 10000000000000010000000 01011111110011101101001 111111111...
output:
00100000001000000010110 00111111111111111111111 11011111101111101111111 01101111111111111111111 01110111111111111111111 01111011111111111111111 01111101111111111111111 01111110111111111111111 01111111011111111111111 01011111101101111101001 11111111110101111111111 01111111111011111111111 011111111001...
result:
ok 23 lines
Test #38:
score: 0
Accepted
time: 210ms
memory: 52212kb
input:
23 00000000000100011000000 00000010001000000011000 00001011010111000000011 00000100100000000101100 00100011010111000000011 00010000100000000101100 01101001011111000011011 00101010010111000000011 00010100000000000101100 00101011000111000000011 01000010000000000011000 10101011010011011000011 001010110...
output:
00101001010111111000011 00111111111011000111011 11001011011111001010011 01000100101000100111100 11100011011111001010011 01010000101000100111100 01101001011011000010011 11101010011111001010011 01010100001000100111100 11101011001111001010011 01111111110011000111011 10101001010011001000011 111010110111...
result:
ok 23 lines
Test #39:
score: 0
Accepted
time: 219ms
memory: 52268kb
input:
23 00000000010100001010010 00011001100010100000001 00000110001011010100100 01001001100010100001001 01010001100010100000001 00100010001011010110100 00100100001011010100100 01011000100010100000001 01011001000010100000001 10000000000100001010010 00100110000011010100100 10000000010000001010010 011111111...
output:
00100110011101011111110 00111011101011110101101 11001111111111110110111 01001001100000100001001 01110011101011110101101 10100010011101010110110 11101101111111110110111 01111010101011110101101 01111011001011110101101 10100110001101011111110 11101111110111110110111 10100110011001011111110 011010111010...
result:
ok 23 lines
Test #40:
score: 0
Accepted
time: 192ms
memory: 52332kb
input:
23 00010100000000001100000 00010000000011000000001 00000011000100010011010 11000100000011001100001 00000100001000000000000 10011000001000001100000 00100001000100010011010 00100010000100010011010 00000000000000100010100 00000000000000010000001 00001100000000000000100 00100011000000010011010 010100000...
output:
01011100000011001100000 10010000010011001100001 00000011110100110011010 11000000000011001100000 10000100101000101100100 10001000000000001100000 00100001110100110011010 00100010110100110011010 00101011001100100011110 01100011000111010001011 00001000100000100000100 00100011110000110011010 110100000100...
result:
ok 23 lines
Test #41:
score: 0
Accepted
time: 188ms
memory: 52212kb
input:
23 00100010100001001001000 00000001000010000000010 10010010110101111011000 00100000010100110010010 00000101001000000000100 00001001001000000000000 10100000100001001001000 01001100001010000000010 10100010000001001001000 00110000000100110010000 00001101000000000000000 00110000010000110010000 010000010...
output:
00100010110101111111001 00010101011110110010010 10000010110101111010000 01000000010110110010010 00000100001000000100100 01001001001010000100100 10100000110101111111001 01000100001010000000000 10100010010101111111001 11110010100111111010010 01001101000010000100100 11110010110011111010010 010101010111...
result:
ok 23 lines
Test #42:
score: 0
Accepted
time: 201ms
memory: 52236kb
input:
23 00000001001000011010000 00001110000100000001011 00000000010000100000100 00000000000011100100000 01000110000100000001011 01001010000100000001011 01001100000100000001011 10000000001000001010000 00000000000010000000001 00100000000000010000000 10000001000100001010000 01001110001000000001011 000100001...
output:
00000001000000011010000 00001111101100001011011 00000000010000000000100 00000000100011100100100 01000111101100001011011 01001011101100001011011 01001101101100001011011 11001110001100011011010 01011110000011000101011 00100000000000010000100 01001111000100001011010 01001111001000001011010 000100001000...
result:
ok 23 lines
Test #43:
score: -100
Wrong Answer
time: 188ms
memory: 52268kb
input:
23 00000000000010000010100 00000011000000010000000 00000101000000100001000 00000000110000000000000 00000000101000101100001 00100001000000100001000 01000001000000000000000 01100110000000100001000 00011000011000000000000 00010000100001000000010 00001000100000000000000 00000000000001000010000 100000000...
output:
00000000000110010010100 00000010000000010000000 00000111000000101101000 00000000111000000000010 00000000001000001100001 00100011000000101101001 01100101000000010001000 00100110000000000001000 00010000001000000000000 00010000000000000000010 00011000100000001100001 10000000000001000010110 100000000000...
result:
wrong answer 3rd lines differ - expected: '00000111000000101101001', found: '00000111000000101101000'