From the Suffocating rules on PG 183 of the PHB A creature can hold its breath for a number of minutes equal to 1 + its Constitution modifier (minimum of 30 seconds). When a creature runs out of breath or is choking, it can survive for a number of rounds equal to its Constitution modifier (minimum of 1 round). At the start of its next turn, it drops to 0 hit points and is dying, and it can’t regain hit points or be stabilized until it can breathe again. For example, a creature with a Constitution of 15 can hold its breath for 3 minutes. If it starts suffocating, it has 2 rounds to reach air before it drops to 0 hit points. Unless a character has a swim speed, it costs 2 feet of movement for every 1 foot traveled. So so long as they still have breath and are not unconscious they can swim have their movement speed.