UVA and UVB Protection
The UVA and UVB ratings refer to the two types of ultraviolet radiation that comes from sunlight. A rays are responsible for the damage done over time by exposure to the sun, and are the major cause of skin cancer. B rays are what cause sunburns now and can result in skin cancer later.
Both types of ultraviolet rays can damage the skin either immediately or over time, and both can lead to skin cancer with prolonged exposure over the years. Your sunscreen should protect against both types of UV rays. Sunscreens that are reinforced against both UVA and UVB exposure will either say "UVA/UVB protection" or "broad spectrum" protection.
Water-Resistant Versus Waterproof
While the titles may seem similar, there is a difference between sunscreen labeled as water-resistant and waterproof. Waterproof is the stronger of the two and generally provides protection in water for up to 80 minutes. Water-resistant is only effective for about 40 minutes in the water.
When using sunscreen in the water, apply early to allow the protection to soak in. Reapply any time you towel off for a break, or after the 80/40 minutes have elapsed. There's no true waterproof sunscreen that guarantees a whole day of water-soaked protection without reapplication, so make sure to keep your bottle handy!