Untitled

 avatar
unknown
c_cpp
a year ago
384 B
6
Indexable
#pragma once

#include <iostream>

class String
{
public:
    explicit String( const char* str );

    ~String();

    String& trim();

    friend std::ostream& operator<<( std::ostream& os, const String& str )
    {
        os << str.m_value;

        return os;
    }

private:
    void ltrim();
    void rtrim();

    char* m_value;
    int m_length;
};
Editor is loading...
Leave a Comment