Witam !
Można w jakiś sposób wyłączyć obsługę trójznaków w Visual Studio. Zmagam się obecnie z tym zdanie na SPOJ:
http://pl.spoj.com/problems/WI_TRIGR/
I napisałem taki kod:
#include <iostream>
#include <string>
#include <regex>
#include <cstdio>
#include <cstring>
std::string text;
using std::string;
string do_replace(string const & in, string const & from, string const & to)
{
return std::regex_replace(in, std::regex(from), to);
}
int main()
{
getline(std::cin,text);
std::cout << do_replace(text, "\\??'", "^") << std::endl;
system("pause");
return 0;
}
Na razie chciałbym aby zamienił poprawnie jeden trójznak, jednak gdy wpiszę na wejście ??' to na wyjściu otrzymuję ?^