Mariah Carey thinks her and Nick Cannon ''could have worked''.

The 'When You Believe' hitmaker insists she will ''always'' be family with her ex-husband, with whom she has nine-year-old twins Moroccan and Monroe.

Writing in her new memoir, The Meaning of Mariah Carey, she said: ''Honestly, I think Nick and I could have worked it out between the two of us, but egos and emotions got inflamed ... It was tough. We both wanted to make sure everything was cool for our family. We will always be family, and we make it work. He was a good guy. He was faith-based. He was ambitious. He had been in the entertainment industry for a long time, so he understood the madness. He paid attention to me.''

Meanwhile, Nick says no one could ''hold a candle'' to his ex Mariah.

Speaking about his ex-wife, he said: ''I mean, it's Mariah Carey. How am I supposed to be? She's one of the most talented women to ever this planet. I can't hold a candle to that woman ... We talked everything out. What if this and what if that. We talked about how much fun it would be if we just got married three weeks into knowing each other. It was more that whimsical fantasy idea of let's have as much fun as we possibly can and when it no longer feels like fun, when it feels like a task and a job, then we should amicably be able to move on. I always used to say it [the relationship] worked so well because it was a healthy balance. I had no problem falling back. It was never a competition with me. It was like, 'I'll turn mine off so she can turn hers on.' I was comfortable in myself and who I was.''