会员
周边
新闻
博问
闪存
赞助商
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
代码改变世界
Cnblogs
Dashboard
Login
Home
Contact
Gallery
Subscribe
RSS
Steve
随笔档案-2012年05月
Lua 中相互调用方法
2012-05-09 22:09 by AlexDotNet, 634 阅读,
收藏
,
摘要: test.lua1 function fact(n)2 if n==0 then3 return 14 else5 return n*fact(n-1)6 end7 end定义一个fact methodhi.lua1 dofile("test.lua")2 n=fact(3)3 print(n)dofie加载 test.lua获取fact方法调用成功Debug 输出...ok
阅读全文
0 Comment
About