riyadhalnur:
the tutorial on the arduino site uses uno which has a removable microcontroller but the Leonardo doesn't have that option. how do I go about doing that?
There is a tutorial about Arduino Uno as an ISP programmer that teaches you how to program a Target AVR without removing the microcontroller from Arduino board.
see: http://pdp11.byethost12.com/AVR/ArduinoAsProgrammer.htm
I believe the method will also work for Leonardo.