added Either and times
refactored reverse