if...elseif....else...end,这是lua中的条件判断语句。
-- if (条件) then -- ... -- elseif (条件) then -- ... -- else -- ... -- end n = 10 if (n==1) then print (1) elseif (n==5) then print (5) else print ('hehe') end >> hehe
if...elseif....else...end,这是lua中的条件判断语句。
-- if (条件) then -- ... -- elseif (条件) then -- ... -- else -- ... -- end n = 10 if (n==1) then print (1) elseif (n==5) then print (5) else print ('hehe') end >> hehe
转载于:https://www.cnblogs.com/wangyueyouyi/p/9944834.html