Lua的基本語法結構

1.Lua的值和類型 (1)數值類型:如1,2,3,1.2,3.14等; (2)字符串類型:雙引號表示,如"Hello World"; (3)布爾類型:true,false; 代碼調用如下: a=1 b="hello world" c=false print(a,b,c) 運行結果如下: 2.Lua的Table Table=數組+映射 (1)數組 a={} a[1]=10 a[2]=20 a[3]
相關文章
相關標籤/搜索