結果
| 問題 |
No.3012 岩井星人グラフ
|
| コンテスト | |
| ユーザー |
srjywrdnprkt
|
| 提出日時 | 2025-03-12 23:22:15 |
| 言語 | C++23 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 327 ms / 2,000 ms |
| コード長 | 616 bytes |
| コンパイル時間 | 3,717 ms |
| コンパイル使用メモリ | 275,252 KB |
| 実行使用メモリ | 7,324 KB |
| 最終ジャッジ日時 | 2025-03-12 23:22:27 |
| 合計ジャッジ時間 | 11,680 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 23 |
ソースコード
#include <bits/stdc++.h>
//#include <atcoder/modint>
using namespace std;
//using namespace atcoder;
using ll = long long;
//using mint = modint998244353;
int main(){
cin.tie(nullptr);
ios_base::sync_with_stdio(false);
int n, m, now=0;
cin >> n >> m;
cout << n*m << " " << n*m << endl;
for (int i=0; i<n; i++) cout << i+1 << " " << (i+1)%n+1 << endl;
now = n+1;
for (int i=1; i<=n; i++){
cout << i << " " << now << endl;
for (int j=0; j<m-2; j++){
cout << now << " " << now+1 << endl;
now++;
}
now++;
}
return 0;
}
srjywrdnprkt