Mac Mini/Xcode/OS Mountain Lion issue
Hi everyone,
I'm a complete newbie to macs and I'm having a tough time figuring a couple of things out. I basically bought a mac mini so I can use Xcode. I went to try and download it but when it finishes and I open the Xcode file I get a message that says "Xcode Not Supported On This Archtecture". I hit software upgrade but it stays stuck on version 10.5.8. Then I see that you can pay $20 bucks for the newest Mountain Lion update.
Do I need to get Mountain Lion in order for Xcode to work on my Mac Mini?
For further info, I signed up as a developer and I have the 3 gig version of the Mac Mini. I've heard kind of confusing things regarding Xcode with people saying it's free but others saying you have to pay an annual fee. At the moment I haven't paid for anything relating to Xcode.
Basically my main question is, how do I get Xcode up and running?
Sorry if this is all super rookie bush league but I'm brand new to the mac world.
Thanks for all your help.
Mac mini, Mac OS X (10.5.8)