[formatting]
[fix] resolve dependency, move i iterator into inner loop, via @leonidborisenko patch