tolocalestring() 方法返回当前数字的字符串值版本,其格式可能会根据浏览器的本地设置而有所不同。
示例您可以尝试运行以下代码来返回字符串值版本 -
<html> <head> <title>javascript tolocalestring() method </title> </head> <body> <script> var num = new number(150.1234); document.write( num.tolocalestring()); </script> </body></html>
以上就是如何将当前数字返回为字符串值版本?的详细内容。
