Changed script to take integers instead of lists.
Added test for writer. Added private constructors.