added tests for past_end?()
first working version of full script