One of the simplest way to deploy code from one environment to another is to use Change Sets. Few clicks and you're done.
Another way is to use ANT migration tool. In this you prepare package.xml
file. In that you specify components which you need to deploy. Followed by some commands for retrieving them from source and then deploying it to target environment. Force.com IDE is used to retrieve Metadata.
Now coming to your question, which is best.
Above two methods have some pros and cons.
Change Sets:
pros: Can be used only within connected environments. e.g. Sandbox to sandbox, sandbox to production.
cons: Time consuming, since you need to each component manually and it takes time.
ANT:
pros: Fast and efficient. Gives more control during deployment. Can edit metadata contents on fly. e.g. Sandbox to sandbox, sandbox to production, developer to production..
cons: I haven't found any.
For ANT, you can refer these sample files needed for deployment using ANT