This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include <string> | |
| #include <cstddef> | |
| void remove_trailing_spaces(std::string& str) | |
| { | |
| bool trailing{false}; | |
| int prev_begin{}; | |
| int removed_spaces{}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include <string> | |
| #include <array> | |
| std::array<std::string, 10> figures{ | |
| "", | |
| "One ", | |
| "Two ", | |
| "Three ", | |
| "Four ", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <tuple> | |
| #include <variant> | |
| #include <type_traits> | |
| #include <utility> | |
| template < | |
| template <typename Q> typename MetaProj, | |
| typename... Ts> | |
| class PackProjector | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <tuple> | |
| #include <variant> | |
| #include <type_traits> | |
| #include <utility> | |
| template < | |
| template <typename Q> typename MetaProj, | |
| typename... Ts> | |
| class PackProjector | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| template<long MIN, long MAX> | |
| struct BoundedInteger | |
| { | |
| BoundedInteger() | |
| { | |
| value_ = MIN; | |
| } | |
| BoundedInteger(long value) | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| template<long MIN, long MAX> | |
| struct BoundedInteger | |
| { | |
| BoundedInteger() | |
| { | |
| value_ = MIN; | |
| } | |
| BoundedInteger(long value) | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ////////////////// LIBRARY START | |
| #include <memory> | |
| template <typename Common, typename R = void, typename ...Args> | |
| class I { | |
| public: | |
| template <typename T> | |
| I(const T& x) : mptr{std::make_unique<Model<T>>(x)} {} | |
| I(const I& other) : mptr{other.mptr->clone()} {} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include <vector> | |
| #include <memory> | |
| template <typename Common> | |
| class I { | |
| public: | |
| template <typename T> | |
| I(const T& x) : mptr{new Model<T>(x)} {} | |
| I(const I& x) : mptr{x.mptr->clone()} {} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <iostream> | |
| #include <vector> | |
| #include <memory> | |
| template <typename T> | |
| void concrete_impl(const T& t) | |
| { | |
| std::cout << "concrete implementation \n"; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from imgur_downloader import ImgurDownloader | |
| list = \ | |
| ['https://i.imgur.com/TQVJygN.jpeg'] | |
| for str in list: | |
| ImgurDownloader( | |
| str, delete_dne=True, debug=True | |
| ).save_images() |