Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@sofar
Created June 23, 2018 06:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sofar/14a3a037dbbfc5e05acb1d25736b1112 to your computer and use it in GitHub Desktop.
Save sofar/14a3a037dbbfc5e05acb1d25736b1112 to your computer and use it in GitHub Desktop.
$ lua
Lua 5.3.4 Copyright (C) 1994-2017 Lua.org, PUC-Rio
> players = { "a", "b", "c" }
> i = 1
> print (#players and i < 50)
true
> for i = 1, #players and i < 50 do
>> print(i)
>> end
stdin:1: 'for' limit must be a number
stack traceback:
stdin:1: in main chunk
[C]: in ?
>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment