From Blockhead to Blockchain Wizard in 10 minutes…

appa
6 min readFeb 4, 2018

--

When I started learning about blockchain, there was so much confusing jargon & terminology. The Interwebs were chock-a-block (eesh!) with just plain wrong or contradictory information. So I wrote this jargon-free piece to simplify it for myself, where I cover a lot of ground from Blockchain to Ethereum to ICOs and proof-of-stake. Block 10 minutes of time (aargh!) and take a step towards Blockchain Wizardry….

  1. What is a blockchain? A block chain is a distributed (spread across the world), decentralized (not controlled by any one entity) database (software to store information)
  2. What is a node? The blockchain is decentralized and lives on a peer-to-peer network of nodes. A node is one of the computers in the network. Each node has all the blockchain data, and all nodes have exactly the same data.
  3. What is a transaction? A transaction is a fancy way of saying “Add some information to the database”. This information is written to the database in “blocks”. All blockchain transactions are atomic (the data is either fully written or not written at all). Since all nodes on the blockchain must have the same data, there has to be a way for all the nodes to agree on adding the “block” of data to the already existing “chain” (“Hey, what a cool name, blockchain!”, not really…). The way that all nodes agree to add a block is called a consensus protocol (jargon alert!)
  4. What is mining? …and that brings us to mining (the most complicated part of this write-up, stay with me!). Each transaction is sent to miners, which is a special type of node in the network, that in addition to having all the data in the blockchain also does some “work”. Miners are given a mathematical puzzle to solve (puzzle: find a number such that the SHA-256 hash of the data in the block and the number — called a nonce — starts with a particular prefix). The cool thing about this puzzle is that it’s hard to solve but fast to verify. Now, the miner that solves the puzzle first lets all the other nodes know the solution (so they can individually verify the answer), and the block is added to the chain. This is how consensus is established across the blockchain (all nodes can be sure they’re adding the same data). At any time, anyone can look at the blockchain and verify by looking at the nonce that the data in the blockchain hasnt changed. Also, because the miner did work to solve the puzzle, the miner is paid for its effort.
  5. What is bitcoin? … and that brings us to bitcoin. Bitcoin one example of a blockchain. Its primary use has been as a decentralized (no central bank) crypto-currency. The crypto-currency is also (unfortunately) called bitcoin. If I were to send 50 bitcoin to you, this is recorded as a transaction on the blockchain. Since this is about currencies, to sound more financial & business like, the term public ledger is used (instead of decentralized, distributed database). Once a transaction is on the blockchain, it becomes “immortal”, and so is a source of truth. This is how bitcoins allow for trust to be established without a central authority.
  6. What is Ethereum? Ethereum is just another type of blockchain. In addition to having a crypto-currency named ether (not Ethereum, learn something you guys at bitcoin!), and transactions to record information, Ethereum also supports the ability to run code. So, each transaction in Ethereum can also (optionally) be associated with code that runs when the contract is executed.
  7. What is a smart contract? Smart contracts are the code that are associated with Ethereum transactions. Typically, they are an if-this-then-that kind of code. In bitcoin, I can say “Send 50 bitcoin from me to you”; in Ethereum, I can say “Send 50 ether from me to you if the temperature outside is more than 100 degrees F” (more typically, when strike price is hit, or when sale date has passed etc.). So, smart contracts captures the agreement between two parties to transact when some condition is met. This smart contract is pushed onto the blockchain, and will run whenever the condition is met.Couple of technical notes — the smart contract runs on all existing & future nodes of the blockchain; also, the consensus is established not on the block data (like in bitcoin), but on the value of the block data after the code is run.
  8. What are DAPPs? DAPPs are just a (horribly IMHO) term for decentralized apps. As a concept, a DAPP is an app that runs across a peer-to-peer network of nodes, so BitTorrent would be an example. However, in the case of Ethereum, the term is used specifically to mean the application, including user interface (through a webpage, say) to the smart contract (since smart contracts are just pieces of code that reside on the blockchain and offer no way for users to work with them directly).
  9. What is an ICO? An ICO, or an Initial Coin Offering is a way to raise money (fundraising or crowdfunding) for a new product or service. It’s all the rage in the Valley for new products. To do an ICO, you create your own crypto-currency (typically on Ethereum, which is trivial to do) and publish a whitepaper (business plan) on your product or service. Then you create hype and offer investor some “coin” from the currency you’ve created in exchange for real, cold cash (actually, ether or a wire transfer will do the trick!). Typically, your product or service will require users to use the crypto-currency you’ve created to use the product (or service). So, if your product or service is a superhit, the value of the currency goes up, and so early investors who gave you money for coin at the initial coin offering make a bomb. This is all theory — to my knowledge few people have made money in ICOs, though lots of people are putting money into different ICOs!
  10. What is proof-of-work? What is proof-of-stake? What’s the difference? Remember mining? The miners doing work to establish consensus between the different nodes by solving puzzles? That is called proof-of-work, as every node can prove the answer easily that the (successful) miner did indeed do work. Unfortunately, as the blockchain grows large, miners have to do more and more work, which consumes lots of power (environmentally unfriendly) and makes it harder to grow the network. So, a spiffy new idea is needed to establish consensus… and that’s proof-of-stake. The idea is that a particular node is selected to add the block to the chain based on the stake the node has in the network… as an example, if the node has a lot of money in the network (value) or has lots of coin that is old (age), then the node has a disincentive to break trust. So, if that node adds the transaction to the blockchain, consensus can be established. It’s basically establishing consensus between untrusted members by them trusting the oldest and wealthiest guy! This is faster, and scales better. Moving to proof of stake is being experimented in Ethereum.

Whew! And that’s it — all you need to know. The one thing I didn’t write about is what can you do with Ethereum? The hype is that this will become the future of the Internet. More pragmatically, Ethereum smart contracts are being used for decentralized file-storage apps, identity and reputation systems, for journalism that combats fake news, and even for prenup agreements!

As a shout-out to my employer, Microsoft is a member of the Enterprise Ethereum Alliance and you can easily get started with Blockchain on Windows Azure very easily!

Now that you’re a blockchain wizard, go ahead and like my article to make it a blockbuster…

--

--