Testing for equality across a sequential table

19 Views Asked by At

In , I can easily test that numerous values are equal, like so:

>> (=  1 1 1 1)
true

My question is, how do I do this for a sequential table (e.g., [1 1 1 1])? My initial though was to use table.unpack, but when I run,

(= (table.unpack [1 1 1 1]))  

I get the error,

Compile error: unknown:1:0 Compile error: expected at least two arguments

0

There are 0 best solutions below