Probably stupid question on pins

I've never created an Arduino project before and have a question about the analog and digital pis. I plan to use both the analog pins and the digital pins and noticed that they use the same numbers. I mean there are Analog pins 0-5 and Digital pins 0-13....what if I want to use BOTH analog pin 3 and digital pin 3?

Do I need to specify what type of pin (port) in my pin assignments or does the Arduino software just sort of....figure it out?

analog pins 0-5 translate to digital pins 14-19 and will not interfere when using analog x and digital blah

So let's say that I assign an LED to analog pin 2 and another LED to digital pin 2 (PWM)...when I say:

analogWrite(2, 255);

Which LED turns on?

analogWrite(2,255) will light up DIGITAL pin 2 at full brightness (continous on). analogWrite is confusing because it ALWAYS writes to a DIGITAL pin!

analogRead(2) works as expected, reading analog pin 2 , while digitalRead(2) reads digital pin 2 (provided you call pinMode(2,INPUT) first.)

[edit]To turn on the LED on analog pin 2, as Osgeld mentioned, you need to refer to it as digital pin 16:
pinMode(16,OUTPUT);
digitalWrite(16,HIGH);[/edit]

I thought anlogWrite() only worked on the PWM pins. If that is true then doing an analogWrite() to digital pin 2 would have no effect.

On most Arduino boards (those with the ATmega168 or ATmega328), this function works on pins 3, 5, 6, 9, 10, and 11.

Keep in mind the analog pins are read only unless they have been designated as digital pins by using digitalWrite(14, xxx), digitalWrite(15, xxx) and so on.

Ah, you're right digimike. I didn't catch that. Thx.

Thanks, I think that's a little more clear now. To save myself from further confusion I think I will go ahead and use the true pin numbers in my program (14-19). Weird that this isn't an FAQ question lol.

I thought anlogWrite() only worked on the PWM pins. If that is true then doing an analogWrite() to digital pin 2 would have no effect.

analogWrite() on a pin that does not support PWM is "clever" and will write LOW for values less than 128, and HIGH for values >= 128...

Good to know. Thanks