improved performance by increasing the index of for-loops properly
Merge pull request #31 from yocaba/master

improved performance by increasing the index of for-loops properly