Is there a method for checking if a table contains a value ? I have my own (naive) function, but I was wondering if something \"official\" exists for that ? Or something mor
Given your representation, your function is as efficient as can be done. Of course, as noted by others (and as practiced in languages older than Lua), the solution to your real problem is to change representation. When you have tables and you want sets, you turn tables into sets by using the set element as the key and true as the value. +1 to interjay.