Do you have another computer and a USB?
If yes, then you can go to the download page for windows 10 (https://www.microsoft.com/en-ca/software-download/windows10)
Then download the media tool.
After click "create installation media for another computer".
Then uncheck "use the recommended options for this PC" and then select your language, the edition of windows you have on the computer you upgraded from windows 8, and choose 32-bit or 64-bit depending on your computer.
After that choose "USB flash drive"
Then select the USB drive from the list.
Now, wait while windows downloads windows 10 on your USB.
When the download is finished take out the USB.
Plug the usb drive into your locked laptop.
Turn on the laptop.
Press any key to boot from the USB drive when you see the message to do so.
Then accept everything.Now when it gives you the option to do a clean install or upgrade click clean install.
Then delete every partition you see until there's one partition called unallocated space.
Select that partition and click next.
Now wait while your computer installs windows 10 again.