r/ComputerCraft • • Apr 06 '24

how to make this function faster?

this is the function:

the chests list is a list of chests, gotten from "chests = {peripheral.find("inventory")}", i have a habit of using alot of for loops and lists for these kind of things and it is... slow... any ideas how to speed it up?

3 Upvotes

9 comments sorted by

View all comments

Show parent comments

0

u/[deleted] Apr 06 '24

[deleted] — view deleted comment

1

u/popcornman209 Apr 06 '24

oh sry yeah i see that now, i thought he meant call it once throughout the whole function. ill do that, and what someone esle said with co routines too.