

They learned how to swim by being thrown in.
Which would by definition be a form of practice.
Which means they learned how to swim by practice.
Which means they did not learn how to swim simply through theory. They first had to practice and then apply the theory they learned, which is still learning by practice.
The spirit of ops question would be reading and learning about it and then being able to jump in the pool and swim without practicing, immediately. Because if you cannot and you first have to practice then by the very statement of this sentence you learned via practice.
Sure it will help. But by no means did you learn how to swim through theory alone.
Which is kind of the whole point of this post