Coefficients and Parameters for contracted Gaussian basis sets
Take a look at the carbon STO-3G first. It means for each AO, you form it with three Gaussians. For carbon, you have a 1S, 2S and (three) 2P. 5 functions when finished.

The top line says you are defining the basis for carbon; no big deal.

Next line says you are creating an S shell, with three primitives, with a 1x scale factor. 

Then you list your three rows of primitives.

The first column is the Gaussian exponent. The next column is the S expansion coefficient. These are the three Gaussians that make up your 1S "Slater" atomic orbital.

In the next section, you define SP. What this is, and I quote from the Gaussian website now: "Note that 2SP requests the best least-squares fit simultaneously to S and P slater orbitals and is not equivalent to separately specifying the best S and the best P expansions."

S and P (and all higher angular momenta, actually) can be related by a recursion relationship. It's an efficient way of computing integrals. I believe the Obara-Saika recursion takes advantage of this, though in Gaussian the integrals are formed using the PRISM algorithm.

The first column is the exponent for your Gaussian, the second column is the S expansion coefficient, and the third column is the P expansion coefficient. They just share the same exponent. Thus you have 4 + 1 (from before) = 5 AOs total formed with three primitives each.

To jump ahead to your last example, the pattern simply continues. The first section gives six primitives to form one 1S (the 6 in 6-311++G**). The second section gives three Gaussians for you valence S and P, the third section is one Gaussian for valence SP. This is the 31 in 6-31++G**. You have a split valence description, one with three primitives, one with a single primitive.

The next section is the diffuse function, hence the really small exponent in the first column. This is the ++ part of the 6-31++G**. The small exponent gives a really wide spreading Gaussian. Helpful for describing electronic activity far from the nucleus. (It's helpful to compare with the huge exponents in the first section, which gives really tight functions that describe the core electrons).

Finally, you have the D functions which are polarization functions. Carbon doesn't have a D valence shell, but we include them to describe polarization of electronic density in molecules.

Note that depending on your program, you either have 5D AOs or 6D AOs. This is the difference between spherical and cartesian representations, and is more of a computational trick than anything else. Gaussian uses 5D by default, except in some cases.