Think of it this way:
A well educated inteligencia, being necessary to the prosperity of a free state, the right of the people to keep and read books shall not be infringed.
This would not mean that the people only have a collective right to keep and read books only if they happen to be enrolled in a school or university. For people to be educated, they must know how to read. The "right of the people to keep and read books" is recognized as already existing, but being that the prosperity of a free state depends on a "well educated inteligencia", it is in the best interests of a free state not to infringe upon the "right of the people to keep and read books", otherwise the people would be illiterate.