During mining, your Bitcoin mining hardware runs a cryptographic hashing function (two rounds of SHA256) on what is called a block header. For each new hash that is tried, the mining software will use a different number as the random element of the block header, this number is called the nonce. Depending on the nonce and what else is in the block the hashing function will yield a hash which looks something like this:

The Bank for International Settlements summarized several criticisms of bitcoin in Chapter V of their 2018 annual report. The criticisms include the lack of stability in bitcoin's price, the high energy consumption, high and variable transactions costs, the poor security and fraud at cryptocurrency exchanges, vulnerability to debasement (from forking), and the influence of miners.[187][188][189]
Unfortunately, “participating” in Bitcoin mining isn’t the same thing as actually making money from it. The new ASIC chips on the market today are specifically designed for mining Bitcoin. They’re really good at Bitcoin mining, and every time someone adds a new ASIC-powered computer to the Bitcoin network, it makes Bitcoin mining that much more difficult.

More broadly, the region is watching uneasily as one of its biggest natural resources—a gigantic surplus of hydroelectric power—is inhaled by a sector that barely existed five years ago and which is routinely derided as the next dot-com bust, or this century’s version of the Dutch tulip craze, or, as New York Times columnist Paul Krugman put it in January, a Ponzi scheme. Indeed, even as Miehe was demonstrating his prospecting chops, bitcoin’s price was already in a swoon that would touch $5,900 and rekindle widespread doubts about the future of virtual currencies.
Price fluctuations, which have been common in Bitcoin since the day it was created eight years ago, saddle miners with risk and uncertainty. And that burden is shared by chip manufacturers, especially ones like Bitmain, which invest the time and money in a full custom design. According to Nishant Sharma, the international marketing manager at Bitmain, when the price of bitcoin was breaking records this spring, sales of S9 rigs doubled. But again, that is not a trend the company can afford to bet on.
Illiquidity. This is mostly moot due to Bitcoin’s $47 market cap but it still makes users sweat. It’s highly unlikely that Bitcoin’s price would plummet and you’d be unable to take action, but it’s still unsettling.  As more investors invest, however, illiquidity becomes a negligible risk, as there will likely always be a buyer for Bitcoins waiting.
The bitcoin blockchain is a public ledger that records bitcoin transactions.[64] It is implemented as a chain of blocks, each block containing a hash of the previous block up to the genesis block[a] of the chain. A network of communicating nodes running bitcoin software maintains the blockchain.[30]:215–219 Transactions of the form payer X sends Y bitcoins to payee Z are broadcast to this network using readily available software applications.

About a year and a half after the network started, it was discovered that high end graphics cards were much more efficient at bitcoin mining and the landscape changed. CPU bitcoin mining gave way to the GPU (Graphical Processing Unit). The massively parallel nature of some GPUs allowed for a 50x to 100x increase in bitcoin mining power while using far less power per unit of work.
Computing power is often bundled together or "pooled" to reduce variance in miner income. Individual mining rigs often have to wait for long periods to confirm a block of transactions and receive payment. In a pool, all participating miners get paid every time a participating server solves a block. This payment depends on the amount of work an individual miner contributed to help find that block.[8]
Bitcoin, the first cryptocurrency ever created has indeed become the most widely used digital currency on earth. Ever since the existence of Bitcoin in 2009, it has witnessed unprecedented growth across the world. The reason for its worldwide acceptance is no other than its ability to changed the way transactions are conducted in many electronic platforms. Conventionally, electronic card transactions take approximately three business days to get confirmation. On the other hand, Bitcoin transactions take few minutes to be confirmed on the blockchain.

In the process of mining, each Bitcoin miner is competing with all the other miners on the network to be the first one to correctly assemble the outstanding transactions into a block by solving those specialized math puzzles. In exchange for validating the transactions and solving these problems. Miners also hold the strength and security of the Bitcoin network. This is very important for security because in order to attack the network, an attacker would need to have over half of the total computational power of the network. This attack is referred to as the 51% attack. The more decentralized the miners mining Bitcoin, the more difficult and expensive it becomes to perform this attack.
As noted in Nakamoto's whitepaper, it is possible to verify bitcoin payments without running a full network node (simplified payment verification, SPV). A user only needs a copy of the block headers of the longest chain, which are available by querying network nodes until it is apparent that the longest chain has been obtained. Then, get the Merkle branch linking the transaction to its block. Linking the transaction to a place in the chain demonstrates that a network node has accepted it, and blocks added after it further establish the confirmation.[2]
The primary purpose of mining is to allow Bitcoin nodes to reach a secure, tamper-resistant consensus. Mining is also the mechanism used to introduce bitcoins into the system. Miners are paid transaction fees as well as a subsidy of newly created coins, called block rewards. This both serves the purpose of disseminating new coins in a decentralized manner as well as motivating people to provide security for the system through mining.
Indeed, for a time, everything seemed to come together for the miners. By mid-2013, Carlson’s first mine, though only 250 kilowatts in size, was mining hundreds of bitcoins a day—enough for him to pay all his power bills and other expenses while “stacking” the rest as a speculative asset that had started to appreciate. By then, bitcoin was shedding its reputation as the currency of drug dealers and data-breach blackmailers. A few legitimate companies, like Microsoft, and even some banks were accepting it. Competing cryptocurrencies were proliferating, and trading sites were emerging. Bitcoin was the hot new thing, and its price surged past $1,100 before settling in the mid-hundreds.
As more miners join, the rate of block creation will go up. As the rate of block generation goes up, the difficulty rises to compensate which will push the rate of block creation back down. Any blocks released by malicious miners that do not meet the required difficulty target will simply be rejected by everyone on the network and thus will be worthless.
The Bitcoin network shares a public ledger called "blockchain". This ledger contains every transaction ever processed, allowing a user's computer to verify the validity of each transaction. The authenticity of each transaction is protected by digital signatures corresponding to sending addresses, allowing all users to have full control over sending Bitcoins from their own Bitcoin addresses. In addition, anyone can process transactions using the computing power of specialized hardware and earn a reward in Bitcoins for this service. This is often called "mining".
In the blockchain, bitcoins are registered to bitcoin addresses. Creating a bitcoin address requires nothing more than picking a random valid private key and computing the corresponding bitcoin address. This computation can be done in a split second. But the reverse, computing the private key of a given bitcoin address, is mathematically unfeasible. Users can tell others or make public a bitcoin address without compromising its corresponding private key. Moreover, the number of valid private keys is so vast that it is extremely unlikely someone will compute a key-pair that is already in use and has funds. The vast number of valid private keys makes it unfeasible that brute force could be used to compromise a private key. To be able to spend their bitcoins, the owner must know the corresponding private key and digitally sign the transaction. The network verifies the signature using the public key.[3]:ch. 5