If you're ever in a situation where you've lost control and especially if you're in sea water (salty) I recommend learning to back float. It uses little energy, allows you to breath and honestly you shouldn't enter the ocean at any reasonably deep depth without knowing how to do this.
It works because you are on your back which is broad, you fill your lungs with air which give you buoyancy and it buys you a lot of time to regain energy to swim towards safety. Even in multi-foot wave conditions you can position yourself perpendicular to the shore, head towards the sea and you raise up and down with the currents, much like a surf board does in that position.
I've used this many times while snorkeling and short on breath in water far over my head, for instance.
It works because you are on your back which is broad, you fill your lungs with air which give you buoyancy and it buys you a lot of time to regain energy to swim towards safety. Even in multi-foot wave conditions you can position yourself perpendicular to the shore, head towards the sea and you raise up and down with the currents, much like a surf board does in that position.
I've used this many times while snorkeling and short on breath in water far over my head, for instance.
This does not protect you from sharks.