Solutions:
The capacity to do work is energy, and the amount of energy expended equals the amount of work completed. The coolie X will do more work because his work involves a change in potential energy, kinetic energy, and energy loss due to friction, whereas the work done by the coolie Y carrying the load on a horizontal frictionless surface does not involve a change in potential energy, kinetic energy, or energy loss due to friction.