Please get to the BIOS Screen and check if the Notebook shuts down in BIOS as well
If the issue persists please contact HP Support in your region for service options
1) Click on this link - www.hp.com/contacthp/
2) Select your product type below.
3) Enter the serial of your device.
4) Select the country from the drop-down.
5) Select the chat or get phone number options based on your preferences.
6) Fill the web-form and proceed further.
Be alert for scammers posting fake support phone numbers and/or email addresses on the community. If you think you have received a fake HP Support message, please report it to us by clicking on "Flag Post".