reimplemented stuff with generic lazy list input
removed old implementation
renamed stuff
check for end of input