Hello richpit10, and welcome to the CameraLabs forum!
So you've already done some research? This is a better start then some of the other newbies here
Your focus is on lenses? Cheers to that too!
Now be warned
: If you go with the Nikon D40/x which is a very good camera indeed, you may occasionally not be able to autofocus with a lens that works normal on any other current Nikon body, because they left out the focus-motor in the D40/x-body
I myself own a lens that would not work on a D40/x: the 10.5mm fisheye and also many of the cheaper third-party lenses e.g. from Sigma don't autofocus with the D40/x either. See the thread here: http://www.cameralabs.com/forum/viewtopic.php?t=749
As to the options for lenses that work on Canon- and Nikon-bodies there is no easy answer.
First of all you need to know that the third-party lens manufacturers like Sigma, Tamron and Tokina make their lenses with both Nikon- and Canon-mounts. So that's a draw.
Secondly: There are some good lenses in the Nikon portfolio, like the famous 18-200mm VR which is the best in class, but on the other hand Canon has some lenses, that Nikon cannot match, like the 10-22mm.
So you should carefully think about what lens(es) you'd like to have. This may already make the decision, unless you're aiming at the third-party lenses. Beware though that most of them (third-party lenses) don't have lens-based IS, which is a must have, since neither Nikon- nor Canon-bodies do have camera-based-IS
And - as the saying goes - you get what you pay for: So normally the third-party lenses have less optical/built-quality than the Nikons and Canons...
Thomas (beware: Nikon-fanboy and moderator!) My Lens Reviews
, My Pictures
, My Photography Blog