c++ parse int from string - Stack Overflow
stackoverflow.com
Note that std::stoi will throw exception of type std::invalid_argument if the conversion cannot be performed, or std::out_of_range if the conversion results in overflow (i.e when the string value is too big for int type).
visual c++ - Convert MFC CString to integer - Stack Overflow
stackoverflow.com
Q: How to convert a CString object to integer in MFC? A: The first requirement for the CString object is that it must contain only numbers. A string can contain a lot of digits, maybe more than an integer can handle. To be able to convert it to an integer, you also need to know how many digits fit in an integer in C++. This can vary per platform.
c++ - Чем заменить функцию stoi? - Stack Overflow на русском
ru.stackoverflow.com
В программе нужно перевести строку в целое число. Я пытался использовать функцию stoi для этой цели, но она не принимается - выходит ошибка: 'stoi' was not declared in this scope В частности, мне н...
c++ - C++11にstd::stouiがないのはなぜ? - スタック・オーバーフロー
ja.stackoverflow.com
C++11でstd::stoiが追加されていますが、std::stouiがありません。これはなぜですか? std::stoulやstd::stoullはあるのに… またunsigned intに入れるためにはどうするのがベストでしょうか。
c++ - За какую ассимптотику работает std::stoi? - Stack Overflow на русском
ru.stackoverflow.com
В связи с решением одной задачи, в которой я из - за std::stoi получила TL, мне стало интересно - за сколько эта функция работает (в плане ассимптотики). Хотя точные цифры тоже было бы неплохо.
Como converter string para o tipo int em C?
pt.stackoverflow.com
Tentei utilizar o itoa(), mas parece que a plataforma URI não aceita, alguém poderia me dar outra forma de converter de string para int? Aqui está o código que eu tentei itoa(n1, p1, 10);
c++ - Modulo de STRING y INT - Stack Overflow en español
es.stackoverflow.com
Tengo un problema a la hora de resolver un problema,el cual me pide que a un string N le saque el modulo de un entero D (los valores de estos,son grandes),el problema,es que cuando utilizo la funcion "stoi" me salta un error,Como lo puedo solucionar?
¿Cómo convertir una string a int en c++? - Stack Overflow en español
es.stackoverflow.com
A partir del estándar C++11 existe la función stoi, a la cual se puede acceder incluyendo la cabecera <string>. Dicha función en su forma más general tiene la signatura:
c++ - Converting from a std::string to bool - Stack Overflow
stackoverflow.com
What is the best way to convert a std::string to bool? I am calling a function that returns either "0" or "1", and I need a clean solution for turning this into a boolean value.
c++ - How to convert a std::string to double - Stack Overflow
stackoverflow.com
Output: 99.999 (which is double, whitespace was automatically stripped) Since C++11 converting string to floating-point values (like double) is available with functions: stof - convert str to a float stod - convert str to a double stold - convert str to a long double As conversion of string to int was also mentioned in the question, there are the following functions in C++11: stoi - convert ...