Hi:
If the hard drive failed the diagnostics test and produced a 24 character failure ID code, you will need to replace the hard drive and reinstall the operating system.
Below is the link to the service manual, where you can find the hard drive removal and replacement procedure.
HP Notebook PC (Intel)HP 250 G4 Notebook PCHP 256 G4 Notebook PC Maintenance and Service Guide
After you replace the hard drive, you can reinstall W10 for free by making bootable installation media using the media creation tool from the link below.
Download Windows 10 (microsoft.com)
After W10 has completed installing, you can install the drivers and available software from your notebook's support page.
HP Notebook - 15-ac101tu Software and Driver Downloads | HP® Customer Support