If there is cigarette smoke in your residence and you are moving out (or moving in) it is very important to remove the smell first. Lingering cigarette smoke can cause you to lose your deposit or can bring down what you residence is worth.
A common mistake made by most people is to spray excessive amounts of air freshener and hope that it will rid the residence of cigarette smoke. This is good for an immediate fix, but it will not get rid of the cigarette smoke smell. Air fresheners will only cover up the smell and mask it for a brief period of time.