Please do try these troubleshooting steps that may help.
- Start by doing a hard reboot, remove the battery and unplug the AC adapter then press and hold the power button for 20 seconds then try if it will stay on or not.
- If the same problem will persist remove the battery off the laptop again then power it on with just the AC adapter connected and see if it will stay on.
-If it will still shut down, do try a different AC adapter still without the battery connected and see if it will stay on.
- If it will stay on with a different AC adapter connected put the battery back in and see if it will charge normally.
- But if the laptop will still shut down with a different AC adapter the problem lies inside the motherboard.
- Do reseat the RAM's, remove them all for couple of seconds then put them back in making sure everything is seated properly.
- If all these will not work, do contact Lenovo for a repair if the laptop is still under the factory warranty.