This is PoW. That's the technology Satoshi invented, and that's the most used one. Beside giving your altcoin a true value unlike the valueless PoS coins, this is the strongest way of securing a coin if you have a good decentralisation of the miners, and enough miners, of course !