By Newton's second law,
n + (-w) = 0
p + (-f ) = (20 kg) (2 m/s²)
where n is the magnitude of the normal force, w is the weight of the box, p is the magnitude of the applied force (p for push or pull), and f is the magnitude of the friction force.
Calculate the weight of the box:
w = (20 kg) (9.80 m/s²) = 196 N
Then
n = w = 196 N
and
f = µ n = 0.5 (196 N) = 98 N
Now solve for p :
p - 98 N = 40 N
p = 138 N