My iPhone 7+ has something wrong with it, every time I take a picture with flash it completely dies it's weird can anyone

My iPhone 7+ has something wrong with it, every time I take a picture with flash it completely dies it's weird can anyone - 1

Battery problems.

Either it isn't charged up or it's bad.

It dies on any percentage whenever I take the photo with the flash it just goes off

Reboot your phone. You do that by hold the power button and the volume down button for like 20 seconds, basically until the phone fully turns off and you see the logo. After you see the logo you can let go.

If this does not work then take it to apple check with them

if that does not work then clear all your multitasking apps or programs and try taking a picture

if this doesn't work then try plugging in your phone and take a picture with it plugged in, if it dies then restore your whole phone (don't forget to save your stuff) and hopefully you should be good.

The issue is the battery. What is happening is normally your phone is drawing fine from the battery. Taking a picture is a huge draw on the battery. Causing a voltage spike.
Your iphone battery should be about 5.5 volts. Your battery sounds like it is going bad and may be only reaching something like 4.5 volts. The phone can work with this but you take a picture and it gets to close to that max voltage. Add a flash on there and you're pushing it over the edge. The phone doesn't get enough current to keep it running and it dies. But it now has enough current again and just turns back on.
Sort of like fainting. Your brain doesn't get enough oxygen to keep you conscious and you passout for just a moment. Waking up in a daze not know what just heppend. I feel this analogy wasn't necessary but I find it a fun different way to understand what I just explained.

You can take your phone to a local repair shop to get a new battery installed. Or take it to Apple, which will cost your more, but people seam to feel better about.