#include <iostream>
using namespace std;
bool replace(std::string& str, const std::string& from, const std::string& to) {
size_t start_pos = str.find(from);
if(start_pos == std::string::npos)
return false;
str.replace(start_pos, from.length(), to);
return true;
}
int main() {
string texto = "gabriel = 1.73,derp = 1.80,";
replace(texto, "1.73", "1.75");
cout << texto;
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgp1c2luZyBuYW1lc3BhY2Ugc3RkOwoKYm9vbCByZXBsYWNlKHN0ZDo6c3RyaW5nJiBzdHIsIGNvbnN0IHN0ZDo6c3RyaW5nJiBmcm9tLCBjb25zdCBzdGQ6OnN0cmluZyYgdG8pIHsKICAgIHNpemVfdCBzdGFydF9wb3MgPSBzdHIuZmluZChmcm9tKTsKICAgIGlmKHN0YXJ0X3BvcyA9PSBzdGQ6OnN0cmluZzo6bnBvcykKICAgICAgICByZXR1cm4gZmFsc2U7CiAgICBzdHIucmVwbGFjZShzdGFydF9wb3MsIGZyb20ubGVuZ3RoKCksIHRvKTsKICAgIHJldHVybiB0cnVlOwp9CgppbnQgbWFpbigpIHsKCXN0cmluZyB0ZXh0byA9ICJnYWJyaWVsID0gMS43MyxkZXJwID0gMS44MCwiOwoJcmVwbGFjZSh0ZXh0bywgIjEuNzMiLCAiMS43NSIpOwoJY291dCA8PCB0ZXh0bzsKCXJldHVybiAwOwp9