[ Web Proxy ]
URL:
Viewing: https://ru.cppreference.com/cpp/string/basic_string/stof [Back]  [Original]

std::stof, std::stod, std::stold cppreference.com
cppreference.com

std::stof, std::stod, std::stold

cppreference.com
 
C++
(C++20)
(C++20)
(C++11)
(C++20)
/
(C++11)
(C++11)
(C++11)
(C++17)
 
 
std::basic_string
-
(C++17)
,
/
( C++20)( C++20)( C++20)( C++20)( C++20)(C++20)
(C++11)(C++11)(C++11)
(C++11)(C++11)
(C++11)(C++11)(C++11)
(C++11)
(C++11)
 
<tbody> </tbody>
float stof( const std::string& str, size_t *pos = 0 );
(1) ( C++11)
double stod( const std::string& str, size_t *pos = 0 );
(2) ( C++11)
long double stold( const std::string& str, size_t *pos = 0 );
(3) ( C++11)

str.

( std::isspace), . , . :

  • . :
  • ()
  • , ( C) ( )
  • () e E, ( 10)
  • . :
  • ()
  • 0x 0X
  • , ( C) ( )
  • () p P, ( 2)
  • . :
  • ()
  • INF INFINITY
  • . :
  • ()
  • NAN NAN( ) NAN. , . NaN .
  • , C

pos. pos NULL, .

str
pos

, .

std::invalid_argument,

std::out_of_range,

.

(C++11)(C++11)(C++11)

() []
(C++11)(C++11)

() []

Web Proxy Viewer  |  New URL  |  Original Page