the logic of the language designers.
If you write
int *p1, p2;
the meaning is clear. This is why fluency in the language is critical if
you are going to use it for anything significant. If you have difficulty
distinguishing between variable declaration and dereference operators,
you're going to have a great deal of trouble getting things to work.
This is not meant to flame, that's just how it is.
Yes, that's why you should neve declare more than one variable at once in C/C++.
a.) See above.
b.) One can make the argument that you should never repeat yourself. If
a set of variables *must* be the same type for code to make sense [i.e.
assignments and such between them], then one should declare them with
the same type identifier. For example,
float *matrixA,
*matrixB,
*matrixC;
is preferable to
float *matrixA;
float *matrixB;
float *matrixC;
and is helpful when you want to change the type to, say, double.
Clearly, using C++ reduces the need to maintain pointers of things [you
could have a matrix class of sorts: matrix<float> A, B, C; ].
The bottom line is when intuition yields results that are incompatible
with reality, you must move beyond what your intuition offers.
Or better, choose another programming language. Are we all
implementing kernel level programs? I doubt it.
C++ is quite powerful, especially when combined with a decent set of
libraries [like Boost]. One need never write C code unless a C++
compiler for the target architecture doesn't exist.