fully implemented reading, checking and writing

Now, to implement additional features :)