Getting into coding consistently bothers me because of the annoying practice of many programmers to put the variable type before the variable itself. I do not like it for three reasons. One, it's redundant. Two, it's ugly. Three, it prepends a constraint to the object in the name.
On complaining to the others who use it, i'm told that it helps a coder quickly get into something because he does not need to look back for the declaration. However, if the programmer is not looking back, i don't want him touching my code anyway. Either you know the variable personally, or you don't know it at all. And that notation simply helps the slackers.
IMNSHO, this programming style is used by (MBTI) Ps, and hated by Js. This is also one of those times i think the P should give in to the J because laziness in coding can have disastrous consequences.
This type of coding is mistakenly called Hungarian Notation. Created by a Hungarian Microsoft programmer, and looking odd, it got its name. However, this is not Hungarian Notation.
But then something kind of wrong happened.
The dark side took over Hungarian Notation.
Nobody seems to know why or how, but it appears that the documentation writers on the Windows team inadvertently invented what came to be known as Systems Hungarian.
Somebody, somewhere, read Simonyi's paper, where he used the word "type," and thought he meant type, like class, like in a type system, like the type checking that the compiler does. He did not. He explained very carefully exactly what he meant by the word "type," but it didn't help. The damage was done.
Apps Hungarian had very useful, meaningful prefixes like "ix" to mean an index into an array, "c" to mean a count, "d" to mean the difference between two numbers (for example "dx" meant "width"), and so forth.
Systems Hungarian had far less useful prefixes like "l" for long and "ul" for "unsigned long" and "dw" for double word, which is, actually, uh, an unsigned long. In Systems Hungarian, the only thing that the prefix told you was the actual data type of the variable.
So, i used to say i hated Hungarian Notation, i can now revise that. Hungarian Notation is a wonderful in many environments. The only difference is, i use it slightly differently. I use it hierarchically. For example, when creating a schema in a database, if there is a subset of TABLEs, i will usually pick a short prefix and use it on all the TABLEs. CONSTRAINT names are somewhat similar.
In vaiables, if a variable is specific to an item, such as his example of an offset, i'd probably call it something like ListBox_Offset. That is, if the list box was called Process_List (i use both underscores and mixed case for readability) it would be Process_list_Offset. Well, the scenario will change it based on context and use, but everything that has to do with Process_List, will get exactly that, plus an underscore, as a preface.
And finally, if for some reason i had to specify the variable type, it'd be at the end, not at the beginning. There is no int class that has my variable within it. Int is merely a constraint on the variable.
I have not read the Microsoft paper yet. I think i shall get to that soon enough.