Is there an equivalent in Tcl of 'string to X' functions found in C stdlib.h?

后端 未结 5 1436
南旧
南旧 2021-01-19 17:50

There are standard functions such as atof and atoi in C\'s stdlib.h for converting strings to floats / integers (and to do the reverse

5条回答
  •  面向向阳花
    2021-01-19 18:28

    One can test string is double $x before using $x in expressions.

    E.g., [string is double 1.2.3] returns 0

提交回复
热议问题