foreachi

LUA

foreachi

foreachi (TABLE, FUNC)

Executes FUNC over numerical indices of TABLE. FUNC is called repeatedlywith the index and respective value as arguments, in sequential order, from 1 to getn(table). Loop exits if FUNC returns any non-nil value, and this value is returned as the flnal value.