News for hackers. Stuff that matters.
Re:How to Write Unmaintainable Code – Naming by pacaro on Tuesday May 26, 2015 @01:54AM (#9603151)
ii, jj, and kk, are easier to search for (although I have jj mapped to <ESC> in vim...)

index, jndex, and kndex, are preferred, obviously.

Re:How to Write Unmaintainable Code – Naming by ajuc on Tuesday May 26, 2015 @02:28AM (#9603224)
If you have to search for loop index variable, your code has worse problems than naming.

I mean - I don't recall writing a loop longer than 2 screens in years. Usually a loop is less than half a screen long.

And anyway, you can search for [^\w]i[^\w] if you really need to.

Maybe it's aquired taste, but in array-heavy code (usually math-related) I much prefer A[i][j][k] * B[j][k][i] than the same with long names for index variables.

Re:How to Write Unmaintainable Code – Naming by carlob on Tuesday May 26, 2015 @03:36AM (#9603378)
or \bi\b
Re:How to Write Unmaintainable Code – Naming by belovedeagle on Tuesday May 26, 2015 @02:09AM (#9603187)
jj = <ESC> changed my life; I'm not even joking. I even went so far as to put my zsh in vi mode and added jj there too. (WARNING: doing this will result in a pathological need to type jjk whenever you open a shell to start scrolling through history.)
Re:How to Write Unmaintainable Code – Naming by arrc on Tuesday May 26, 2015 @02:24AM (#9603213)
I prefer mapping <ESC> to <CAPSLOCK>. Hitting single keystroke. I quickly got tired of hitting 'jj' every time I need to escape.
Re:How to Write Unmaintainable Code – Naming by Rainymood on Tuesday May 26, 2015 @02:25AM (#9603214)
I personally use 'kj', which is just a natural roll from my middle to my index finger. Have you tried this?