Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 31/07/24 in all areas

  1. This method works, it's able to match: for i, numbersValue in ipairs(numbersTable) do for j, dataValue in ipairs(data) do if data[j] == numbersValue then print('match found: '..numbersValue, v) break end end end Thanks Tails
    1 point
  2. Could you share the structure of your tables and what you're trying to match exactly? table.find is not a function in Lua, you have to either run another loop or if the data table has the same structure you can do this: for i, v in ipairs(numbersTable) do if data[i] and data[i] == v then print('match found', v) end end or maybe with a loop: for i, numbersValue in ipairs(numbersTable) do for j, dataValue in ipairs(data) do if data[j] == numbersValue then print('match found', v) break end end end It all depends on how your tables are structured and how you want to match it, it's kind of hard to guess what the best approach is.
    1 point
×
×
  • Create New...