So the analog pins, can they also be used for example digital output?
And what are those insanely awesome trocks? :o
I have been staying away from pin 1 and 2 because the guide book does it
[/quote]
-
Yes, the pins that are connected to the ADC (there is one Analog/Digital Converter) are also digital pins.
-
The ones I know best involve switching pin mode and/or direction to make the same wired circuit behave in different ways. The speed of the Arduino to do this plays a major part, switching or reading a digital a pin generally takes less than half a millionth of a second.
-
examples of awesome tricks that can save you parts/code (ie money and work) which IIRC is almost as awesome as catching on to how FAST these things work:
a) So you can go from lighting a led through a resistor using two pins to, with no change in wiring, using the same led as a light sensor and back so fast that human eyes can't see it was ever off. That trick lets you make a code+circuit that self-adjusts its own brightness when background light changes. It is used in some TV remotes, phones, etc.
b) You can use two pins, a few cheap parts and some foil or other conductive surfaces to make proximity/touch sensors with similar tricks as light-sensing with a led. Really, from switches that have no moving parts and can work from under cover material to sections of wall or floor that sense if someone is standing within a meter or so, capacitive sensing can do the job at low cost.
c) If you have more switches than pins the first trick you do is multiplexing by putting the switches on a grid of wires from X pins by Y pins, a 3x4 is good for 12 switches. If you want to be able to read many switches pressed at the same time then you turn all the pins off and quickly read just 1 pin on each side of the grid at once (to read only one switch) and go through 12 switches in a few miroseconds and know which ones are pressed or not though caveat, most switches need "debouncing" so it can take a few milliseconds to be SURE the switch is pressed. 
d) If you need even more switches for the same number of pins then there is a trick called charlieplexing. I have no simple explanation of it, look it up if you need as the full explanation is a page or so. The wiring is hard and so is the code, I haven't needed to do it beyond experiment that convinced me it's only for when you really need it!
e) If you don't have enough analog pins or you want to sense analog values quicker than analog read (can take 105 microseconds to do a 10 bit read, less to do "fast" analog read) at lower resolution (say I only want 16 value-steps instead of 1024 or you want to be able to errrr, say that your device reads fifty shades of gray in less than a tenth of a millisecond) then you can set up a charge holder (capacitor or even just a length of wire or else) that you charge (make HIGH) with the same pin that you turn around and read until it goes LOW. How long that took tells you the charge. The same "time the discharge" technique can let you measure higher resolution than 10-bit ADC but it takes longer, way longer.
I cheat a bit here. This is behind examples a and b. It is also how cheap PC joystick adapters work.
f) You can adjust PWM rates to do neat stuff but I have yet to need to so save that for looking up.
That's all I've got off the top of my head and my typing fingers.