I don’t think you are asking the right question. Swimming pools do not create algae, it is primarily caused by an excess of nutrients like nitrogen and phosphorus, combined with warm water, sunlight, and stagnant conditions.
So the chlorinated water in swimming pools will not grow algae unless dead leaves or other organic matter is left to accumulate eg in an outdoor pool.
You can stop algae from growing by reducing excess nutrients, limiting sunlight, and maintaining proper water circulation.
So in outdoor ponds etc, you need to remove decaying leaves, fish waste, and excess food, which feed algae.
Also ensure regular water changes to lower nitrate and phosphate levels.
Avoid using fertilizers near ponds .
Indoors, you should shade the water using floating plants or a nearby structure.and also reduce the daily lighting hours in aquariums to six or eight hours max.
Where possible, use opaque or dark-coloured containers for stored water to block light.