結果

問題 No.893 お客様を誘導せよ
ユーザー claw88claw88
提出日時 2019-09-27 21:34:53
言語 C++14
(gcc 12.3.0 + boost 1.83.0)
結果
AC  
実行時間 18 ms / 2,000 ms
コード長 1,171 bytes
コンパイル時間 1,598 ms
コンパイル使用メモリ 169,972 KB
実行使用メモリ 4,348 KB
最終ジャッジ日時 2023-10-25 01:57:27
合計ジャッジ時間 2,285 ms
ジャッジサーバーID
(参考情報)
judge13 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
4,348 KB
testcase_01 AC 2 ms
4,348 KB
testcase_02 AC 3 ms
4,348 KB
testcase_03 AC 9 ms
4,348 KB
testcase_04 AC 10 ms
4,348 KB
testcase_05 AC 9 ms
4,348 KB
testcase_06 AC 6 ms
4,348 KB
testcase_07 AC 2 ms
4,348 KB
testcase_08 AC 18 ms
4,348 KB
testcase_09 AC 2 ms
4,348 KB
testcase_10 AC 2 ms
4,348 KB
testcase_11 AC 2 ms
4,348 KB
testcase_12 AC 3 ms
4,348 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include "bits/stdc++.h"
using namespace std;
#define mod 1000000007
#define dom 998244353
#define all(c) begin(c),end(c)
#define rep(i,n) repi(i,0,n)
#define repi(i,a,b) for(int i=(a);i<(b);i++)
#define rrep(i,a,b) for(int i=(b)-1;i>=(a);i--)
template <typename T> bool chmax(T &a, const T &b) { if (a < b) { a = b; return true; } return false; }
template <typename T> bool chmin(T &a, const T &b) { if (b < a) { a = b; return true; } return false; }
#define long long long
#define List vector
#define var auto
#define Count size()
#define Length size()
#define in :
#define foreach for
int dd[] = { 0, 1, 0, -1, 0 }; //→↓←↑

int P[1024][128];
void solve()
{
	int N; cin >> N;
	for (int i = 0; i < N; i++)
	{
		int k; cin >> k;
		P[i][0] = k;
		for (int j = 0; j < k; j++)
		{
			cin >> P[i][j + 1];
		}
	}

	var L = List<int>();

	for (int t = 0; t < 100; t++)
	{
		for (int i = 0; i < N; i++)
		{
			if (P[i][0] <= t)
			{
				continue;
			}

			L.push_back(P[i][t + 1]);
		}
	}

	rep(i, L.size())
	{
		cout << L[i] << " ";
	}
	cout << endl;
}

int main()
{
	cin.tie(0);
	ios::sync_with_stdio(false);
	cout << fixed << setprecision(11);
	solve();
	return 0;
}
0