This is a benchmark I ran and this is the result: table.find is faster.
Script in question?
local list = {}
local char = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"
for i = 1,1000 do
local str = ""
for x = 1,5 do
local hash = math.random(1,#char)
str ..= char:sub(hash,hash)
end
table.insert(list,str)
end
local randomChar = list[math.random(1,1000)]
local st = tick()
for i = 1, #list do
if randomChar == list[i] then
table.remove(list, i)
end
end
print("Took "..tick()-st.." seconds.")
st = tick()
table.remove(list,table.find(list,randomChar))
print("Took "..tick()-st.." seconds.")