結果
| 問題 |
No.5007 Steiner Space Travel
|
| コンテスト | |
| ユーザー |
ococonomy1
|
| 提出日時 | 2023-04-26 23:20:07 |
| 言語 | C++17(gcc12) (gcc 12.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 1,000 ms |
| コード長 | 1,661 bytes |
| コンパイル時間 | 1,272 ms |
| コンパイル使用メモリ | 111,204 KB |
| 実行使用メモリ | 4,376 KB |
| スコア | 1,799,259 |
| 最終ジャッジ日時 | 2023-04-26 23:20:14 |
| 合計ジャッジ時間 | 3,285 ms |
|
ジャッジサーバーID (参考情報) |
judge15 / judge13 |
| 純コード判定しない問題か言語 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 30 |
ソースコード
//#pragma GCC target("avx2")
//#pragma GCC optimize("O3")
//#pragma GCC optimize("unroll-loops")
#include <iostream>
#include <iomanip>
#include <algorithm>
#include <vector>
#include <string>
#include <set>
#include <map>
#include <cassert>
#include <cmath>
#include <tuple>
#include <queue>
#include <bitset>
using namespace std;
using lg = long long;
#define TEST clog << "TEST" << endl
#define IINF 2147483647
#define LLINF 9223372036854775807LL
#define AMARI 998244353
#define TEMOTO ((sizeof(long double) == 16) ? false : true)
#define TIME_LIMIT 980 * (TEMOTO ? 1 : 1000)
#define el '\n'
#define El '\n'
int wakusei_num, station_num;
class planet {
public:
int x;
int y;
int num;
};
bool hikaku_x(planet a, planet b) {
return a.x < b.x;
}
class station {
public:
int x;
int y;
int num;
};
#define MULTI_TEST_CASE false
void solve(void) {
cin >> wakusei_num >> station_num;
vector<planet> wakusei(wakusei_num);
for (int i = 0; i < wakusei_num; i++) {
cin >> wakusei[i].x >> wakusei[i].y;
wakusei[i].num = i;
}
for (int i = 0; i < station_num; i++) {
cout << "0 0" << El;
}
cout << wakusei_num + 1 << el;
sort(wakusei.begin(), wakusei.end(), hikaku_x);
cout << "1 1" << El;
for (int i = 0; i < wakusei_num; i++) {
if(wakusei[i].num)cout << 1 << ' ' << wakusei[i].num + 1 << el;
}
cout << "1 1" << el;
return;
}
void calc(void) {
return;
}
int main(void) {
cin.tie(nullptr);
ios::sync_with_stdio(false);
int t = 1;
if (MULTI_TEST_CASE)cin >> t;
while (t--) {
solve();
}
calc();
return 0;
}
ococonomy1