Lua中..和#运算符的用法
用法 运算符 lua ..
2023-09-14 09:06:20 时间
Lua中..和#运算符的用法
样例
试试以下的样例就明确了在Lua编程语言提供的其它运算符:
a = "Hello " b = "World" print("Concatenation of string a with b is ", a..b ) print("Length of b is ",#b ) print("Length of b is ",#"Test" )
当建立并运行上面的程序它会产生下面结果
Concatenation of string a with b is Hello World Length of b is 5 Length of b is 4
相关文章
- Go语言 异常panic和恢复recover用法
- Node.js之Console用法小结
- C基础--关于typedef的用法总结
- PHP中大括号{}用法总结
- python os.chdir() 用法
- nginx的location、root、alias指令用法和区别
- Oracle trunc()函数的用法
- js中return的作用及用法
- js的insertRow和insertCell用法
- 分区函数Partition By的与row_number()的用法以及与排序rank()的用法详解(获取分组(分区)中前几条记录)
- Linux中使用SecureCRT上传、下载文件命令sz与rz用法实例
- typescript ts参数展开运算符:形参展开和实参展开及as const的用法示例
- PostgreSQL ECPG ifdef include等预处理用法
- Dev RadioGroup 用法(项横排显示、项选中)
- TypeScript里的空值合并运算符(双问号)用法
- UEditor用法
- lower_bound( )和upper_bound( )的常见用法
- ASP.NET WEB——项目中Cookie与Session的用法
- 模式匹配基础用法