This is expected behaviour. Putting '&' in between two integers is not the same as between two strings. int & int will evaluate to: 'is int not zero' AND 'is int not zero', which in your case is true, so the result is True, which for an int is 1.
The point is, you should use str(loopindex("x")) & str(loopindex("y")) to convert the integers to strings before using the '&' which now means: joint these two strings together.
Your fix does the same thing, but the above is clearer, and explicit.