`img_class` is not a pointer, so use `.` to access a member of that object. Here it will be `img_class.visited[i][j]`.