結果
問題 | No.5009 Draw A Convex Polygon |
ユーザー | Sarievo |
提出日時 | 2022-12-02 20:09:50 |
言語 | C++17 (gcc 12.3.0 + boost 1.83.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 2,773 bytes |
コンパイル時間 | 6,037 ms |
実行使用メモリ | 35,436 KB |
スコア | 0 |
平均クエリ数 | 1000001.00 |
最終ジャッジ日時 | 2022-12-02 20:10:06 |
合計ジャッジ時間 | 11,220 ms |
ジャッジサーバーID (参考情報) |
judge11 / judge13 |
(要ログイン)
ソースコード
// @Sarievo, URL: https://yukicoder.me/problems/no/5009 #pragma GCC target("avx2") #pragma GCC optimize("O3","unroll-loops") #include <bits/stdc++.h> using namespace std; // --- Library --- #if __has_include(<atcoder/all>) #include <atcoder/all> using namespace atcoder; // using mint=modint998244353; using mint=modint1000000007; #endif // --- Type and Alias --- #define a first #define b second #include <ext/pb_ds/tree_policy.hpp> #include <ext/pb_ds/assoc_container.hpp> using namespace __gnu_pbds; // find_by_order() - kth largest (0-indexed) // order_of_key() - count(Si < k) template<class T> using indexed_set=tree<T,null_type,less<T>,rb_tree_tag,tree_order_statistics_node_update>; template<class T> using indexed_multiset=tree<T,null_type,less_equal<T>,rb_tree_tag,tree_order_statistics_node_update>; template<class T> using v=vector<T>; template<class T> using vv=v<v<T>>; template<class T> using minheap=priority_queue<T,v<T>,greater<T>>; template<class T> using maxheap=priority_queue<T,v<T>,less<T>>; using ll=long long; using ld=long double; using vl=v<ll>; using vvl=vv<ll>; using pl=pair<ll,ll>; using vp=v<pl>; // --- IO --- template<typename T> istream&operator>>(istream&is, pair<T,T>&p){is>>p.a>>p.b;return is;} template<typename T> ostream&operator<<(ostream&os, pair<T,T>&p){os<<p.a<<" "<<p.b;return os;} template<typename T> istream&operator>>(istream&is, v<T>&a){for(auto&e:a)is>>e;return is;} template<typename T> ostream&operator<<(ostream&os, v<T>&a){for(auto&e:a)os<<e<<" ";return os;} #define Nyan ios_base::sync_with_stdio(0);std::cin.tie(0);std::cout.tie(0);std::cout<<fixed; // --- Macro --- #define reps(i,start,end_exclusive) for(ll i=(ll)(start);i<(ll)(end_exclusive);++i) #define rep(i,end_exclusive) reps(i,0,end_exclusive) #define sum(a) accumulate(all(a),0ll) #define fore(e,a) for(auto&e:a) #define all(a) (a).begin(),(a).end() #define rall(a) (a).rbegin(),(a).rend() 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 U> bool chmax(T&x,const U&y){return x<y?x=y,1:0;} template<class T,class U> bool chmin(T&x,const U&y){return x>y?x=y,1:0;} template<typename T> inline T abs(const T&x){return (x<0?-x:x);} template<typename T> inline T sqr(const T&x){return (x*x);} void yes(bool x){std::cout<<(x?"yes":"no")<<endl;} void Yes(bool x){std::cout<<(x?"Yes":"No")<<endl;} void YES(bool x){std::cout<<(x?"YES":"NO")<<endl;} // --- Vars --- // R D L U DR DL UL UR ll dx[]{+0,+1,+0,-1,+1,+1,-1,-1}; ll dy[]{+1,+0,-1,+0,+1,-1,-1,+1}; void solve(){ vp pts; rep(i, 1e6){ pts.push_back({i,i*2}); } cout << pts.size() << endl; fore(pt,pts){ cout << pt << endl; } } signed main(){ Nyan; solve(); }