# What is Mining Cryptocurrency?

## Mining cryptocurrency can be a lucrative endeavor with enough computing power

Mining cryptocurrency is in the news a lot lately. People are finding their computers have been compromised by malware and are mining, or in some cases entire botnets are mining. But what does that mean?

This isn’t mining in the traditional sense. There are no pick axes or canaries involved. Instead. it’s more about trying to win a blockchain lottery to earn the reward at the end.

What does that all mean? Let’s hash it out.

## What is cryptocurrency?

To begin a discussion of mining cryptocurrency we need to start with what cryptocurrency is. Cryptocurrency is a digital form of currency with a cryptographic underpinning that is used as a secure medium of exchange. There are literally hundreds of different cryptocurrencies with varying real-world values. Many believe it’s the future of currency.

The most popular cryptocurrency is bitcoin, you may have heard of others like Etherium, too. While cryptocurrencies may differ in terms of the algorithms and encryption they use, they all share one similiarity: blockchain. And that’s what we need to talk about next.

## What is blockchain?

Blockchain is a digital ledger of transactions that is impossible to alter. It uses hashing and a concept similar to salting to continuously complete blocks of information that chain to form an immutable ledger.

Hashing is the act of mapping data of any length to a fixed-length output. When cryptography is involved it’s a one-way function. The most popular hashing algorithm is SHA-256, which outputs at a length of 256 bits. Every hash value is unique. Even the tiniest alteration to the data being hashed caused the entire value to change.

Hashing is considered one-way because of the amount of computing power it would take to reverse-hash it. For a 256-bit output, calculate 2 to the power of 256 (2 X 2 X 2… 256 times). Your odds of finding the correct value are 1 in… the product of that equation. Those are astronomical odds. It would take a supercomputer thousands of years to compute that.

## Blockchain + Cryptocurrency

Now let’s fit it all together. With a cryptocurrency blockchain, as transactions occur they are broadcast and added to various private ledgers. Each one of these transactions is digitally signed for the sake of authenticity. On the other end, there are people or groups collecting these transactions and building ledgers. They are also computing to find a value that when hashed along with the ledger, produces a set number of 0s at the beginning of the hash value. That’s the portion that’s similar to salting.

So let’s say that for our example cryptocurrency, we’ve set the total to 10 0s. That means the first 10 spots of the 256-character hash value should all be 0s.

When the correct value is found, the block is closed, it’s broadcast officially and added to everyone’s blockchain, then the hash of the old block is put atop the new ledger and the process begins again. This is how blocks are created in the chain.

## So, what is mining cryptocurrency?

The act of computing the correct value to satisfy the hash function in blockchain is called mining. When it comes to cryptocurrency, a reward is provided to whoever solves for the correct value. That makes it lucrative to compute the correct value, though it takes quite a bit of power to accomplish that.

Oftentimes people pool their computing power together and split the reward if they solve for the correct value. In other cases, hackers have been known to co-opt others’ computers and use some of their computing power – behind the scenes – to mine cryptocurrency. There are entire botnets doing nothing but mining.

Really, solving for the correct value is like winning the lotto. There are countless people and botnets attempting to find the value and whoever finds it first gets the reward.

Of course, if you can accumulate enough computing power you could solve for the value enough of the time that you could accrue a substantial amount of cryptocurrency.

## Wrapping Up

When someone says “mining cryptocurrency” what they’re referring to is the act of trying to compute a specific hash value by producing a set value that, when hashed along with the block ledger, produces a specific result. This requires considerable computing power, but considering the rewards – it’s well worth it.

## What we Hashed Out (for Skimmers)

Here’s what we covered in today’s discussion:

- Blockchain is an immutable ledger of digital transactions
- Cryptocurrency is a digital currency that is a secure medium of exchange
- Mining cryptocurrency is computing a specific value that produces a specific hash result and completes a block on the blockchain

That’s good again, sir. I like your articles.

But, why are people rewarded for finding the answer to a specific hash result? Why is there value or reward for “creating money” ?

The Bitcoin system was designed to issue a number of Bitcoins to reward the miner who successfully compute the hash value for the new set of transactions. It is like a race for the miners in order to reap the rewards: some newly minted bitcoins. The amount of newly minted bitcoins will diminishes over years.

Mining is used to provide the mathematical work that is used to make the blockchain secure and ineffective against brute force attacks. Miners dedicate their computing resources (and electrical energy) to guess solutions to a cryptographic hash function from the previous block by trying random permutations until the right one (that is verifiable as a solution) is found. That solution is then published to the network, and the miner who found it publishes the next block, with everyone else in the network confirming it. As reward for creating the block, the miner gets a reward of 25 BTC (which will be halved eventually) as a reward for performing the work to secure the block.

Now it takes billions of tries to find the correct cryptographic key, so often, miners congregate in what are called mining “pools” to combine their resources so they have a better chance of finding the next block first. The pool then splits the reward depending on the work each miner did.

Basically, there is a high cost (time and electricity, hardware costs) involved in securing each block. Therefore, a malicious attacked would not only need to dedicate an enormous amount of resources to “spoof” an entry, but also be in competition with all the legitimate miners. At the end of the day, the reward is incentive to keep the miners that secure the network dedicate their resources.

Thanks for the info. Still doesn’t make sense: paying people to make more money…like paying someone to print paper money. I don’t get it. “so dense light bends around him”

Well, you are paying money to the bank to manage and make money out of the money your deposited to them.

Cryptocurrency platform is the best way to money transfer.