2012年5月2日

摘要: >a,b,c,d,e=1,2,"three","four",5print(a,b,c,d,e)R:1 2 three four 5>print(a,b)a,b=b,aprint(a,b)R:nil nilnil nil表示空>1 print("---------------------------");2 3 a,b,c,d,e=1,1.123,1E9,-123,.00084 print("a="..a,"b="..b,"c="..c,"d=&qu 阅读全文
posted @ 2012-05-02 23:25 沙漠之泉 阅读(195) 评论(0) 推荐(0) 编辑
摘要: 01: hello worldcodes:print("hello lua!")print("你好LUA")02.a=1b="abc"c={}d=printprint(type(a))print(type(b))print(type(c))print(type(d))Result: numberstringtablefunction03. 注释on_two_3=123 --is valid varable name--表示注释语句print(_VERSION) --输出lua的版本ab=1Ab=2AB=3print(ab,Ab,AB) 阅读全文
posted @ 2012-05-02 21:21 沙漠之泉 阅读(329) 评论(0) 推荐(0) 编辑
摘要: lua for windows 下载地址:http://code.google.com/p/luaforwindows/一下为转载:lua for windows其实是一整套Lua的开发环境,它包括:Lua Interpreter(Lua解释器)Lua Reference Manual(Lua参考手册)Quick Lua Tour (Lua快速入门)Examples (Lua范例)Libraries with documentation (一些Lua库和文档)SciTE (一个很棒的多用途编辑器,已经对Lua做了特殊设置)其它详细的内容请到luaforge的主页上查看。之所以推荐这套环境是因为 阅读全文
posted @ 2012-05-02 20:53 沙漠之泉 阅读(789) 评论(0) 推荐(0) 编辑

导航