Breastfeeding question

My son is 4 days old today. I started bottle feeding him in hospital and been giving him that since we’ve been home, I didn’t breastfeed bc he wasn’t latching and my milk hadn’t come in. I’ve also started back smoking cigarettes since yesterday . My milk came in today and I want to try to breastfeed. How long do I need to wait to breastfeed him ? How long would it take the nicotine to be out the milk? Can I still breastfeed ?