Removed unnecessary debug output
Bugfix: using loop variable in array indexing instead of static 0