The acceleration is related to the force and mass by Newton's second law which states:

for the first mass we have:

If the same block is hit by a force of 40 N then the new acceleration is:

Which is eight times the original acceleration; therefore, the answer is D.