That's why I was saying I wouldn't try to automate that part. You don't need a super-reliable method if you're doing it by hand. On average, it probably takes a lot longer to count the skittles by hand than it does to open the bag, so most of the savings comes from the part that's easy to do reliably.