In the second case
Case (i)
Mass, m = 15 kg
Displacement, s = 2 m

Case (ii)
Mass, m = 15 kg
Displacement, s = 2 m
Here, the direction of the force appliedon the rope and the direction of the
displacement of the rope is same.
Therefore, the angle between them, θ = 0°
Since cos 0° = 1
Work done, W = Fs cosθ = mgs
= 15 x 9.8 x 2 = 294 J
Hence, more work is done in the second case.