How come on the white phones there are two openings up top and a single opening on the black.? I see the speaker on both but on the white there is a separate one above and not on the black why and what is it used for?

There are two sensors in that top black strip of the white one:
- the proximity sensor. Turns off the phone when you bring it close to your head on a call
- the ambient light sensor. If you turn on "automatic brightness" it will sense the amount of light outside and adjust the brightness accordingly so you can see better.
Btw the black one has this "strip" as well for both sensors... its just that you don't really see it unless you really look for it up close...
Is it on the 3GS? i don't se any evidence on mine
It's on the black iPhone 4 as well, you just can't see it as easily cause it's a black hole on a black phone. On your 3GS you can see it as three little circles next to the speaker.
Look at the front of your phone in direct sunlight, you'll see the three little circles next to the speaker.