changed i to j