This question makes me chuckle because there’s no real answer. I suspect that most authors will say the same thing.
It’s relatively easy to say how long your second novel took to write. Or your third. Or fourth. And so on.
But your first? It took forever! Absolutely forever!, Because your first novel is a learning experience.
You write it. Or maybe you just write part of it. Then you decide that’s wrong, so you tear it apart and write it again. And again. And again. And again.
When the thing is finally finished, you have no idea how long it took, only that it took over your life and your imagination and more time than you’d ever have thought possible.