m = {"John", "Steve", "Kris", "Ben"} m.name = m f = {"Katie", "Susan", "Patricia", "Elizabeth"} f.name = f
How I can display random word from both of those two tables?
Code below I am using for random word from one table, but I can’t figure out how to merge or… tables to be able access words from both. I am thinking about function 50/50 but I am new guy here and I need some help.
Any suggestions?
m = {"John", "Steve", "Kris", "Ben"} tableIdx = math.random(#m) tableWord = m[tableIdx] word = display.newText(tableWord, 100, 100, "Helvetica", 24)