Why We Need A Smart Contract Flashcards
Born concept of the smart contract
Was born there well before the advent of the Bitcoin.
Smart contracts is …
Smart contracts is the centerpiece and main thrust of Ethereum blockchain.
Linux Foundation’s Hyperledger blockchain about Chaincode
Has a smart contract feature called Chaincode.
The docker environment.
The Chaincode is written in go language, and executed in a docker environment.
Docker is a lightweight container technology for executing programs.
Remix development environment
Use remix development environment for building and testing smart contract, and deploy the smart contract using remix, and invoke the contract from a simple web interface.
We’ll use remix integrated web interface for hands-on explorations.
What bitcoin added?
Bitcoin added a simple conditional transfer of value added a simple conditional transfer of value through an embedded script.
That was bootstrapped as a softfork in Bitcoin.
The script was limited in its capabilities.
It enabled simple conditional transfers.
After Bitcoin, envolved Ethereum.
The founders of Ethereum developed smart contract keeping Nick Szabo’s idea of a smart contract from over 20 years ago in mind.
What’s a significant contribution of Ethereum
A significant contribution of Ethereum is a working smart contract layer that supports any arbitrary code execution or the blockchain.
Smart contracts allows
Smart contract allows for user-defined operations of arbitrary complexity. This feature enhances the capability of Ethereum blockchain to be a powerful descentralized computing system.
Why would you wnat to transfer currency? For what?
Cryptocurrencies such as Bitcoin, enable transfer of values such as money or currency from peer-to-peer without any intermediaries.
For what? To give somebody to buy a product, maybe even renew a driver’s license, or send flowers to someone.
Suppose we may want the gift to be delivered on a certain date. Buy a product with a particular color and quality. We may need some credential verified for renewing the license.
Smart contract addresses this need (conditions, rules, policies beyond that of which a simple money transfer cryptocurrency protocols cand handle)for application specific validation for blockchain application.
Advantages of smart contracts
Smart contract has some advantages including, a smart contract facilitates transaction for transfer of assets other than value or cryptocurrency.
Smart contract allows specification of rules for an operation on the blockchain. It facilitates implementation of policies for transfer of assets in a descentralized network. It also adds programmability and intelligence to the blockchain.
What smart contracts represent?
The smart contract represents a businees logic layer, with the actual logic coded in a special high level language.
Smart contract embedded function
Smart contract embedded functions that can be inboked by messages that are like function codes. These messages and the input parameters for a single message are specified in a transaction.
Comparing Bitcoin and Smart contract transaction …
Let us compare Bitcoin transaction and a smart contract transaction. As you can see in Bitcoin, all the transactions are about send value. In the case of a blockchain that supports a smart contract, a transaction could embed a function implemented by a smart contract.f