If a "MacBook", then I'm guessing used. Apple hasn't sold new MacBooks (at least with that name) since the 2010 model was discontinued in July of 2011.
Of course, what you check for depends a lot on which MacBook you are considering.
There's 7 to 10 different MacBook models, depending on how you count them. (and that does not include any MacBookAirs, or MacBook Pros)
If an older MacBook (2006 or 20007, etc), then the battery might be an issue. The hard drives were smaller capacity then, and the plastics on the case can have various (mostly appearance) issues.
As with ANY used laptop, not just Macs, you want to check the screen for condition, hinges for smooth operation, magsafe adapter cable for serviceability. And, of course, on a used Mac (ANY used Mac) you should get a disk that you can use to reinstall OS X if that becomes necessary (many would say that your first task, after purchasing a used Mac, is to erase the hard drive, and reinstall OS X.)
It would also be nice to get a used Mac that has the maximum RAM memory already installed.
If you have purchased Lion, you can install Lion on any Mac that you own, but that Mac must support Lion.
ALL MacBooks will run Snow Leopard.
However - the oldest MacBooks do NOT support installing Lion.
So, again, which MacBook? If you want to upgrade the MacBook to Lion (or Mountain Lion), then you will need to ask the seller exactly which model. If the seller has several different MacBooks, you should be able to purchase one that suits your needs.
The OTHER issue when upgrading to Lion - Lion requires a minimum of 2GB of RAM, where Snow Leopard requires only 1GB.
And, the oldest MacBooks might have even less RAM installed.
Bottom line - we can answer your questions better, if you can give us more details about the specs of the used MacBook that you are looking at.
Xcode is included as one of the optional installs on the Snow Leopard installer DVD.
It's an older version, but should be usable for learning Xcode, and it's free with the system installer.
I understand that you can find the Xcode version 4 for Snow Leopard if you search for the download - or you can sign up as a developer (the $99 that you mentioned)
Or, upgrade to Lion or higher (if your Mac supports that), and Xcode is a free download from the App store. That Xcode requires Lion or newer anyway. And, you can use Xcode for free, until you want to enter the developer program. Good idea, anyway, as the developer program will also give you access to other downloads that you might need - plus, you're a registered developer for Apple at that point!
And - again - it will depend on which model MacBook Pro!
5 different MacBook Pros were sold new in 2006.
The earliest 3 models cannot go to Lion. Those have Core Duo processors. The later two MacBook Pros from 2006 have Core 2 Duo processors, and CAN take Lion.
It really does help when you can supply more details (and also are good questions to ask any seller, if the system details are not apparent to you). If you DO want to go to Lion - that's something that you need to be sure about, so you don't make a mistake when you purchase.
Know what you are getting - ask questions of the seller BEFORE you spend your money. When I sell a used Mac, I will be honest about that Macs capabilities, to the best of my knowledge.
Finally, if the seller can't (or won't) answer your questions - find another seller!
(how many times do I get to say this?)
Depends on which model you have, and the main difference is, you don't usually find out when the MacBook Pro was MADE, but more likely when it was SOLD. The serial number, for example, will tell you when it was manufactured. There's several sites where you can enter the serial number, and the site will respond with the manufactured date, such as here: http://www.appleserialnumberinfo.com/Desktop/index.php
However, some MacBook Pros are sold as refurbs, and those usually have different serial numbers, which might refer to the refurb date, and not the original manufactured date. So - it's not so easy as just asking which one you have. No one here knows which one you have, until you tell us. "Made in 2008" just isn't enough.
The "seller" should be able to answer your questions, if they know anything about the MacBook Pro. If not - choose a different seller!
bottom line - the ability to install, and run a particular version of OS X is BEST determined by knowing what processor you have, and also knowing the system's model identifier, which is available in the system's hardware profiler.