This was successfully debugged by ikegami on Stackoverflow
Just want to help avoid the duplication of effort since OP's typically fail to update their cross-posts.
In reply to Re: Script is writing output twice; second time in reverse order
by wind
in thread Script is writing output twice; second time in reverse order
by theillien1
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |