Difference between revisions of "SHIP:Sail:atof"

From Serious Documentation
Jump to: navigation, search
Line 1: Line 1:
 
__NOTOC__
 
__NOTOC__
 
{{SailFuncTableStart|}}<onlyinclude>
 
{{SailFuncTableStart|}}<onlyinclude>
|{{SailFunc|atof}}||{{DataType|Float}}||style="text-align:center;"|5.0.120||Parses a {{DataType|String}} to get an {{DataType|Float}} from it</onlyinclude>
+
|{{SailFunc|atof}}||{{DataType|Float}}||style="text-align:center;"|5.0.120||Parses a {{DataType|String}} to get an {{DataType|Float}} from it {{v5}}</onlyinclude>
 
|}
 
|}
 
== See Also: ==
 
== See Also: ==

Revision as of 15:50, 29 July 2014

Function Returns Introduced Description
atof Float 5.0.120 Parses a String to get an Float from it Badge SHIPv5.gif

See Also:

Prototype

Float atof(String string);

Parameters/Return Value

Parameter Data Type Description
string String The string to parse
Return Float the floating point parsed value of the String

Detailed Description

The atof(string) function returns the Float parsed value of a String which should contain the string version of an Float or Integer.

Examples

Example Result Notes
atof("-5"); -5.0
atof("+5"); +5.0
atof("5.76"); +5.76
atof("57.89E+3"); +5.789E+4
atof("0.005789E3"); +5.789
atof("57.8X9E+3"); 57.8 Parsing stops at the X