You can always tell if there is a smoker living in a home or an apartment. Smoke smell is one of the most persistent smells there is, and it could be a problem if you purchase a home from a smoker. Unless you are willing to live with the smell, it will be a major project to remove the smell completely.
If you do decide to get into it, your first step should be a thorough cleaning, scrubbing down all surfaces in the home. Light bulbs and their fixtures might need to be replaced, since they can release the odor when they heat up after being turned on. You should also replace filters throughout your home, especially those in your HVAC system, but other filters, such as the one in your kitchen exhaust fan can keep the odor.
Smoke particles are so fine that they can make it into every area of your home, and you will need to root them out to get rid of the smell completely.