#include <string>
#include <memory>
#include <iostream>

struct Logger
{
    virtual void log(std::string s) = 0;
};

struct ConsoleLogger final : public Logger
{
    void log(std::string s) override
    {
        std::cout << s << std::endl;
    }
};

int main()
{
    std::unique_ptr<Logger> p { new ConsoleLogger() };

    p->log("kaas");

    return 0;
}
