-
-
Notifications
You must be signed in to change notification settings - Fork 81
dtl::board::WriteNumber (板書クラス)
Kasugaccho edited this page May 15, 2019
·
2 revisions
<DTL/Board/WriteNumber.hpp>
namespace dtl::board {
template <typename T, typename Char = char>
class WriteNumber;
}
※ T
は1bit以上の型
機能名 | 対応 |
---|---|
非長方形Matrix | 可能✅ |
#include <DTL.hpp>
#include <array>
#include <string>
#include <iostream>
int main() {
std::array<std::array<int, 10>, 10> matrix{ {} };
dtl::Border<int>(1).draw(matrix);
std::string str{};
dtl::board::WriteNumber<int>("\n", "(", "), ").draw(matrix, str);
std::cout << str;
}
(1), (1), (1), (1), (1), (1), (1), (1), (1), (1),
(1), (0), (0), (0), (0), (0), (0), (0), (0), (1),
(1), (0), (0), (0), (0), (0), (0), (0), (0), (1),
(1), (0), (0), (0), (0), (0), (0), (0), (0), (1),
(1), (0), (0), (0), (0), (0), (0), (0), (0), (1),
(1), (0), (0), (0), (0), (0), (0), (0), (0), (1),
(1), (0), (0), (0), (0), (0), (0), (0), (0), (1),
(1), (0), (0), (0), (0), (0), (0), (0), (0), (1),
(1), (0), (0), (0), (0), (0), (0), (0), (0), (1),
(1), (1), (1), (1), (1), (1), (1), (1), (1), (1),
Copyright (c) 2018-2021 As Project.
Distributed under the Boost Software License, Version 1.0.(See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)