It depends on the what your goal is. The idea of leasing is pretty simple, and a lot of people don't understand it. Lets say you want to lease a $50K car for two years, the chances are that your leased car is going to be worth $30K after that time (or even less, go check luxury car prices), therefore the car has dropped in value by $833/mo. I'm willing to bet your monthly lease is going to be around the $900 mark, meaning you've essentially been paying off the diminishing value of the car plus a little extra. Except with leasing you have the ability to claim the lease payment as a tax writeoff.
Now if you're after credit history and you've got cash to boot, I really don't see much reason to buy outright completely either. If you take a 36 month loan and look at it you'll find that you are paying nearly all interest up until around 18 months, at which point you start paying off a substantial amount of principal. What does this mean? Lets say you want your $50K car, you could get the loan with zero down, immediately pay off $30K of it, and then ride out the rest of the $20K knowing that the bank has missed out on most of the interest they would have received otherwise. That is also $20K you can invest elsewhere and profit on. Not to mention if you get a good deal you can sell the car off in a few years to get a bit of your cash back.