There are a few kinds of bankruptcy that you can consider, Chapter 7 and Chapter 13. Each one has its own benefits and downsides, so it's important to learn what you can about them before you decide which to pursue.
After divorce or once you and your spouse separate, you need to develop a plan for your children's care. Parenting time has to be balanced with your work and the life you have now that your marriage is ending. You must agree on how you'll raise your children and how you're going to split your time with them.