This repository has been archived on 2023-05-13. You can view files and clone it, but cannot push or open issues or pull requests.
mipt_cpp/seminar03_initialization/08_stringview/main.cpp
2022-10-22 18:26:37 +03:00

16 lines
409 B
C++

#include <iostream>
#include "miptstring.cpp"
#include "miptstringview.cpp"
using namespace std;
int main() {
mipt::String str = "Meow!!";
cout << str << endl;
mipt::StringView sv = str;
cout << "string view: " << sv << endl;
char a[] = "nyaa!";
mipt::StringView sv1 = a;
cout << "string view: " << sv1 << endl;
cout << sv1.at(200) << endl;
}