Scottish Swimming is calling for every primary school child to get a chance to learn to swim.
Research suggests around a third of Scots children cannot swim when they leave primary school.
The sport's ruling body said delivery of school swimming lessons differs between local authorities, and has launched a campaign called #everychildcanswim.
Ahead of a reception at Holyrood, 40 children from Pirniehall Primary School in Edinburgh were joined by members of Team Scotland for a lesson at the city's Royal Commonwealth Pool.
Kathryn Johnstone, who will swim in the breast stroke at the Glasgow Games this summer, said: "The message is that swimming is fun but it's also an important life skill with added health benefits.
"Being at the age they are, they have the potential to achieve what we have. We train here six times a week, so to have the opportunity for them to swim at this facility for them is brilliant."
Sport Secretary Shona Robison said: "The Commonwealth Games is only months away and this year is an excellent opportunity to inspire a generation of swimmers."