Please note, this is a STATIC archive of website www.tutorialspoint.com from 11 May 2019, cach3.com does not collect or store any user information, there is no "phishing" involved.
Tutorialspoint

tab1

function estimate (flight_context)
    local wingspan = 
     {[15] = 5, [20] = 6, [30] = 7, [9999] = 8}
    print(flight_context.wingspan())
    local value = 999
    for k,v in pairs(wingspan) do
        if(k>flight_context.wingspan() and v<value) then
            value = v
        end    
    end
    return value
end
local fc = {}
function fc.wingspan()
    return 40
end    

print(estimate(fc))

Advertisements
Loading...

We use cookies to provide and improve our services. By using our site, you consent to our Cookies Policy.