You are being very unreasonable to frame your question like that.
It is rarely that simple.
And also, making a unilateral decision about something that affects more than one life is very much the start of being a bad person. It's the start of that road. As in, being inconsiderate, irresponsible, selfish.
The only time when it is absolutely the right thing for the children of a relationship for one of the parents to leave that relationship is when there is abuse- then the kids are subject to abuse and don't grow up thinking that abusive behavior is ok.
I think people can no longer be together and both still be good parents- but I think that takes a huge amount of work and the right attitude. And to be honest, that is so much work that it would probably have been easier and less work to make the relationship work. The sort of people who could make divorce work are the sort of people who manage to make marriage work so never get round to having to make divorce work.
One model that can make that situation workable is "nesting"- kid or kids stay in one home all the time, parents take it in turn to live there. So it's pretty likely that 3 homes are needed.
Very few people have the resources to do that obviously. But many wouldn't do it even if they had the resources, because they wouldn't like the faff/dislocation of traipsing back and forth between two households. Which is exactly what kids get made to do all the time.
Many children of divorce say that one of the worst things is not being able to fully participate in school clubs/activities or social life because they have to make two locations work. They don't feel fully rooted in either family, and find it more difficult to put down their own roots (friendships, hobbies etc) that would stabilize their lives.
Also I hate it when people leave their children and then insist "But my kids come first, I'd do anything for my kids". Well obviously not.
I think it is possible to be a good parent after leaving a relationship, but it's unlikely, because most people aren't prepared to take on that kind of work. So what usually happens is one person, the resident parent, takes on the vast majority of parental work out of necessity, does their best and manages to varying degreees. That person is often a very good parent, but it's always difficult for one person to do the work of two. And sometimes it overwhelms them and they don't manage to do as good a job as if they had a more sensible share of the role.
And I don't think that a leaving parent is someone who has any right to claim that they "put their kids first" or that "my kids are the most important thing in the world to me".