Versions of a game like D&D can be hard to pin down. There is the large number of box sets and beginner setups as well as that fun Advanced thing. I am going to ignore all that and break it down into groups based on the how I see it. This will be highly unscientific and biased. I will say what I think and how I compare it in relation to how "D&D" I feel that it is.
First up is OD&D with its 3 books with or without the few extra addons. This is the original way to play and the quintessential core of true D&D. Even if you don't want to play with the rules a good look through can benefit a DM.
Next up is all the stuff between AD&D and OD&D. Not quite beyond its start but moving towards the AD&D way this is around where a number of people got their start. Lots of boxes reign in this area. It is true to itself with differences here and there and a lot of oddness, overall D&D as far as I can see. I don't know enough to truly differentiate between all the different setups in this category.
Now we get into AD&D. While moving away from the original spirit the apple doesn't fall far from the tree on this one. After the basics a number of people went for this because the "Advanced" in the title made them feel it was more of an adults game. There are more precise rules and a number of confusions from the original is cleared up as well as some shifts in the rules. While it feels close to D&D it has a bit that while still D&D are clues to the future changes. The last few books for it started the down hill motion.
Second Edition AD&D is rules heavy. By some it is considered the fulcrum point between old school and new school and while I feel this is somewhat true it is a beast all to itself. Odd rules and an obsessiveness with realism made a strange creature out of it. It moves away from what it should not and while D&D doesn't feel quite right.
A new wind blows and 3rd edition arrives with its OGL. Closer then second edition AD&D yet still not close while it lasted a good number of businesses sprung up to make products for it. This was a good time for the brand of D&D. Then came 3.5 and the world shuddered. While the corrections that it made to some of the rules where good it hurt the 3rd party businesses and lowered the trust in the brand. This was a point when a number of break off games based on the system that was opened up by the OGL sprung up. The editions with 3 in them overall suffered from an overlarge number of bad splat books and over doing of the feat mechanic. While as mentioned they are both closer to D&D then second edition AD&D it is still farther from my ideal then regular AD&D.
Finally is 4th Edition D&D. I have played a few games of it and was in a short lived campaign for it. As a game it can be fun. Its just not D&D. If they had named it something else then it would have been quite fun but calling it D&D ruined it for me. I don't plan to be playing it anymore. It just doesn't feel right to me. I know people who enjoy the game and that is fine but for me as long as it is called D&D I just can not stomach it. I have been trying for so long to play actual D&D that it would be like being at a restaurant and ordering steak but instead getting some fish. The fish might be good but I wanted a steak.
Overall I can say I would play any of the editions of D&D barring 4th and even that I would play if they had the decency to not call it D&D. That may just be my extreme desire to game coming through but it is an amazing thing. The fact that through all of the change that D&D has gone through I would play them all if given the chance is an amazing feat as I am a generally picky gamer. I will say though that while I would like to DM the older the better because the newer the edition (except maybe 4th, never looked into it) the more you need to put into setup of stats as compared to dungeon design.