Difference between revisions of "Dtostring"

From Mesham
Jump to navigationJump to search
(Created page with '== Overview == The dtostring(d, a) function will convert the variable or value ''d'' into a string using the formatting supplied in ''a''. * '''Pass:''' A Double and [[Stri…')
 
m (3 revisions imported)
 
(2 intermediate revisions by the same user not shown)
Line 9: Line 9:
  
 
  #include <string>
 
  #include <string>
  var a:=23.4352;
+
   
var c:=dtostring(a, "%.2f");
+
function void main() {
 +
    var a:=23.4352;
 +
    var c:=dtostring(a, "%.2f");
 +
};
 +
 
 +
''Since: Version 1.0''
  
 
[[Category:Function Library]]
 
[[Category:Function Library]]
 
[[Category:String Functions]]
 
[[Category:String Functions]]

Latest revision as of 15:44, 15 April 2019

Overview

The dtostring(d, a) function will convert the variable or value d into a string using the formatting supplied in a.

Example

#include <string>

function void main() {
   var a:=23.4352;
   var c:=dtostring(a, "%.2f");
};

Since: Version 1.0