Enhance knight example by monad func composition