Well, I was trying to validate the checkValid function, so I rewrote it in a C++ file and tried to pass the hash and target
to try to do the test, however, the 'checkValid' function is not returning true '1', I tried several different hashes and targets but unsuccessfully.
I don't know if I wrote the correct algorithm in my test example or if the function really isn't working.
Well, I was trying to validate the checkValid function, so I rewrote it in a C++ file and tried to pass the hash and target to try to do the test, however, the 'checkValid' function is not returning true '1', I tried several different hashes and targets but unsuccessfully. I don't know if I wrote the correct algorithm in my test example or if the function really isn't working.
I will leave the code used to do the test here
https://onlinegdb.com/lypx0_9Tx
test-check-hash.txt