Remove unused variables and pre- initialized/assigned iterators (i,j,k)