Declare `j` as local variable -- this name is commonly used in other functions