Writers do this too. Benjamin Franklin learned to write by summarizing the points in the essays of Addison and Steele and then trying to reproduce them.
Raymond Chandler did the same thing with detective stories. Hackers, likewise, can learn to program by looking at good programs—not just at what they do, but at the source code. One of the less publicized benefits of the open source movement is that it has made it easier to learn to program.
Paul Graham, Hackers & painters: Big ideas from the computer age, Cambridge, 2004, p. 41