From the instructions for form W-4:
Exemption from withholding.
You may
claim exemption from withholding for 2018
if both of the following apply.
• For 2017 you had a right to a refund of all
federal income tax withheld because you
had no tax liability, and
• For 2018 you expect a refund of all
federal income tax withheld because you
expect to have no tax liability
Reference: https://www.irs.gov/pub/irs-pdf/fw4.pdf
"Having a tax liability" is after all credits, including refundable credits like the Earned Income Credit and Child Tax Credit.
A single person with $40K income and no kids is extremely unlikely to be exempt.
Reference: https://blog.turbotax.intuit.com/tax-refunds/can-i-file-exempt-still-get-a-tax-refund-6695/