Eliot’s Tips and Tricks

Multiple function returns

Returning multiple values from a function is something that you really learn to enjoy! It makes sense really, functions can take multiple inputs, why not multiple outputs?

Here’s the syntax:

local A,B = Foo('blah')

function Foo(Msg)
   return 1, "Two"

One Comment

  1. Pingback: Will You Share Your Code? - iNTERFACEWARE Inc.

Leave A Comment?

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.