10 string lua types integer ti-nspire
我已经看到很多将字符串转换为整数的答案,但是如何将整数转换为字符串呢?当我尝试时microseconds.toString()出现以下错误:attempt to index upvalue 'microseconds' (a number value)
microseconds.toString()
attempt to index upvalue 'microseconds' (a number value)
请注意,这是在运行操作系统 4.5.0.1180 的 ti-nspire 上
感谢您的任何帮助,您可以提供!
Pig*_*let 3
来自https://www.lua.org/manual/5.1/manual.html#pdf-tostring
弦 (e)
接收任何类型的参数并将其转换为合理格式的字符串。要完全控制数字的转换方式,请使用string.format. 如果e的元表有“ __tostring”字段,则tostring以e为参数调用相应的值,并使用调用的结果作为其结果。
string.format
__tostring
tostring在NSpire Lua 脚本 API 参考指南第1 章第 1 页中提到...
tostring
归档时间:
8 年,5 月 前
查看次数:
21271 次
最近记录:
4 年,11 月 前