結果

問題 No.3191 Operation Puzzle
ユーザー elphe
提出日時 2025-07-12 17:30:54
言語 C++23
(gcc 13.3.0 + boost 1.87.0)
結果
AC  
実行時間 2 ms / 2,000 ms
コード長 544 bytes
コンパイル時間 1,063 ms
コンパイル使用メモリ 84,016 KB
実行使用メモリ 7,848 KB
最終ジャッジ日時 2025-07-12 17:30:58
合計ジャッジ時間 3,343 ms
ジャッジサーバーID
(参考情報)
judge4 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2
other AC * 45
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <cstdint>
#include <vector>

static inline void output(const uint_fast32_t N, const char X) noexcept
{
	std::cout << "Yes\n";
	for (uint_fast32_t i = 0; i != 4; ++i)
	{
		std::cout << X;
		for (uint_fast32_t j = 1; j != 4; ++j)
			std::cout << ' ' << X;
		std::cout << '\n';
	}
}

int main()
{
	std::cin.tie(nullptr);
	std::ios::sync_with_stdio(false);

	uint_fast32_t N, i;
	std::cin >> N;
	std::vector<char> A(N);
	char X;
	for (i = 0; i != N; ++i)
		std::cin >> A[i];
	std::cin >> X;

	output(N, X);
	return 0;
}
0