2 ms·
`x` and `y` are also problematic, though slightly less so. The biggest issue I have is that they're similar in appearance. `abc` is much better, because they'r
by DanHulton 4y ago
`x` and `y` are also problematic, though slightly less so. The biggest issue I have is that they're similar in appearance. `abc` is much better, because they're clearly different from each other, if you're married to single-letter values.
`i` and `j` are usually indicative an index for something, and indicating what you're indexing makes the code clearer to read and easier to maintain. `idxUsers`, `idxPosts`, for example. `x` and `y` are a bit trickier because they're very frequently the canonical positional co-ordinates, and renaming them can actually make it _harder_ to read, so (like all things in naming) is a real judgment call, but frequently can be replaced with `col` and `row`, which, to me reads _much_ clearer, especially when using row-major access pattern: `array[row][col]`.