Original Post
Let's say we have this little convention of prefixing variable names, based on the kind of the variable:
prefix - meaning (sample variable name)
p - pointer (pWindow)
c - class or struct (cBox)
r - reference (rNode)
a - array (aObjects)
f - real number (fTime)
i - integer (iIndex)
n - unsigned integer(nVertices) // usually used for count
What is the disadvantage of using such prefixes versus not using any prefixes for the variable names at all? For example if somewhere in someones code you'd see a cleverly named variable: data What can you say about it and how could you continue using it without looking up its declaration or looking around for other code using that same variable? If the variable was prefixed with p, you'd automatically know that it's a pointer, that you can write -> and hope that intellisense will show you a list of its members, and that you may be concerned by its life time (like make sure that it's destroyed somewhere appropriate using delete). If the variable was prefixed with a, you'd be aware that it's an array of some type, also that you may have to delete it using delete[]. If the variable was prefixed with c, you'd know that you may continue writing a . and see what intellisense has to offer, also that you shouldn't be concerned by its life time, since it will be destroyed when it goes out of scope. If the variable was prefixed with r, you'd know mostly the same stuff as if it was prefixed with c, except that you probably shouldn't be attempting to use the variable as a temporary, since you may overwrite some useful data somewhere outside your current scope. Another advantage of prefixing is that for example if you wrote fps = frameCount / ticks * 1000; you can't say for sure if the result in fps will be an integer or a real number (which you may be expecting), unless you know that at least one of variables frameCount or ticks is of real type. Having them prefixed with n, i or f saves you the time of going to see their declarations, or worse - getting only the integer quotient of the division during playtesting, while you may have expected to get a real value. If you happen to be working in a large function with a lot of different variables it's always easier to remember the kind of variable you currently need rather than its name, so you may just type in its prefix and select the variable you need from the intellisense list. While it's been said around the internet that variable names without prefixes are more readable, you're getting less information from its name and you will end up needing to look up the declaration of the variables in order to know what you must do with them which adds time to reading the code, also burdens your thinking by making you explicitly remember what kind each variable is.