Skip to main content

stod

Convert a string to a double.

stod("123"); //123.0
stod("123.123"), //123.123

Syntax

stod(string)

Returns

  • The string as a double on success.
  • Undefined when the string cannot be converted.