# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
296185 | 2020-09-10T11:46:12 Z | Fasho | Vision Program (IOI19_vision) | C++14 | 0 ms | 0 KB |
#include <algorithm> #include <iostream> #include <cassert> #include <climits> #include <cstdlib> #include <cstring> #include <iomanip> #include <numeric> #include <cstdio> #include <string> #include <vector> #include <cmath> #include <ctime> #include <queue> #include <stack> #include <map> #include <cstdio> #include <unistd.h> #include <cassert> #include <string> #include <set> using namespace std; #define N 500005 #define ll long long int #define fo(i,x,y) for(int i=x;i<=y;i++) #define fs(ar,n) fo(i,1,n) cin>>ar[i] #define sp " " #define fast cin.tie(0);cout.tie(0);ios_base::sync_with_stdio(false) #define pb push_back #define ppb pop_back #define fi first #define se second #define ii pair<int,int> #define lli pair<ll,ll> #define fast2 freopen ("in.txt","r",stdin);freopen ("out.txt","w",stdout); #define inf 1000000000 #define MP make_pair #include "vision.h" using namespace std; // vector<int> v; void construct_network(int H, int W, int K) { int flag=0; for(int i=1;i<=H;i++) { for(int j=1;j<=W;j++) { for(int g=i;g<=H;g++) { for(int h=j;j<=W;h++) { vector<int> v={(i-1)*W+j,(g-1)*W+h} if(g-i+h-j==K) { ll x=add_and(v); cnt++; if(x) flag=cnt; } } } } } vector<int> v; // for(int i=H*W+1;i<=cnt;i++) v.pb(flag); add_or(v); }