当前位置:网站首页>What are the key smart contracts in defi?
What are the key smart contracts in defi?
2022-07-18 16:02:00 【Blockchain Technology Researcher】
People often ask , What is a smart contract ? Then you must first understand what is “ contract ”.
Contracts in daily life ( Cooperation agreement ) That is, between the partners “ contract ”, Now we can hardly live without a contract , Go ahead and say , Work is a labor contract signed with the company , Buying a house is signing a house purchase contract with a real estate company , To buy insurance is to sign an insurance contract with an insurance company ; Say small , online shopping 、 Order take out 、 Take a taxi 、 Buying lottery tickets is to sign corresponding contracts with relevant service providers . so to speak , Where there are people, use contracts .
We even bet , It's also a contract , But if one side denies , Then it will be difficult to fulfill the contract . If there is a contract , Set the rules in advance , Once the relevant terms are triggered , The contract will be executed automatically , Without human intervention , Don't worry about someone denying . Is there such a contract ? There are , This is the smart contract .
What is a smart contract

Intelligent contract (Smart Contract) Last century 90 By Cryptologist Nick · Saab's idea , Due to the lack of a credible execution environment , Smart contracts have not been applied and developed , until The etheric fang Appearance , To make smart contracts “ resurrection ”.
What is a smart contract ? In short, a smart contract is a contract that uses computer language instead of legal language to record terms and is automatically executed by a program . let me put it another way , Smart contracts are digital versions of traditional contracts , Running on the blockchain network , Automatically executed by the program .
vending machine 、ATM ATM , To some extent, it can be understood as a machine executing smart contracts , But this is not a real smart contract .
What are the characteristics of smart contracts ?

Compared with traditional contracts , Smart contracts have three characteristics :1、 The content of the contract is open and transparent Smart contracts are deployed on the blockchain , The content of the contract is naturally open and transparent .
2、 The contents of the contract cannot be tampered with Again , Because it is deployed on the blockchain , The content of a smart contract cannot be modified .
3、 Permanent operation Smart contracts running on the blockchain , Also maintained by the network nodes on the blockchain , As long as the blockchain is in , Smart contracts can run forever . Species “ The chain is in the contract ” A sense of brotherhood .
Smart contract with three characteristics of blockchain , Compared with traditional contracts, it has the following advantages :
1、 To trust .
Because the smart contract is based on blockchain , The content of the contract is open and transparent 、 And not tamper with . Code is law (Code is law), Traders are based on trust in the code , Can be reassured in an environment of mistrust 、 Trade safely .
2、 economic 、 Efficient
Compared with the traditional contract, it is often because of the different understanding of the contract terms , Cause a dispute ; Smart contracts avoid disagreements through computational languages , There is little dispute , The cost of reaching a consensus is very low . On smart contracts , The arbitration result comes out , Effective immediately . So compared to traditional contracts , Smart contracts are economical 、 The advantage of efficiency .
3、 No need for Third Party Arbitration
Suppose Xiong DA and Xiong Er bet , Bet on whether it will rain tomorrow , Whoever loses needs to give it to the other party 100 element . If the loser denies , If you win, you won't get a reward . So , Go to a third-party arbitration institution , Inefficient and time-consuming . But if the bet is written on a smart contract , When the bet is reached , Respective 100 Yuan into the smart contract address , Smart contracts are based on the final results , Automatic execution , The winner takes all the rewards . so , Smart contracts do not require third-party Arbitration .
Is smart contract really smart ?
The above is all about the advantages of smart contracts , Is smart contract really smart and flawless ? It's not , Smart contracts also have their drawbacks .
As mentioned above , The tamper proof properties of smart contracts , It's easy to build trust . But there is also a bad side , If there are loopholes in smart contracts , Hackers can exploit loopholes in smart contracts , Make a profit for yourself .
A simple example , A vending machine , The original price was 5 A soft drink , by mistake , It has been written. 5 dime , After the administrator found out , It can be corrected immediately . But if this vending machine invokes the smart contract on the blockchain , Then this error cannot be modified , Until the drinks are sold out .
On the other hand , The smart contract itself cannot be obtained ( perception ) External information , It involves the need for external information to adjudicate the contract , You need to write relevant information to it , It can make a decision . For example, Xiong DA and Xiong Er bet whether it will rain tomorrow , The smart contract itself doesn't know whether it rained the next day or not , It needs to be provided with information through other information sources , For example, the data of the Central Meteorological Observatory , Oh, after this information , Smart contracts make decisions .
From the two points above , Smart contracts are neither perfect nor smart .
Summary
in summary , About smart contracts , We know :
Smart contract uses computer language instead of legal language to record terms 、 A contract executed automatically by a program . It deployed on the block , It also has the data openness and transparency of blockchain 、 No tampering 、 Characteristics of permanent operation .
Compared with traditional contracts , Smart contracts have to be trusted 、 Security 、 Efficient 、 Advantages of not requiring third-party Arbitration . But smart contracts are not perfect , And it's not intelligent, or its intelligence is very low .
It is mentioned in the article that the execution of smart contracts does not need the judgment of a third party , At the same time , When the execution condition involves external information , Smart contracts cannot be perceived , You need to input relevant information into the smart contract , To trigger the smart contract to enforce the ruling .
边栏推荐
- 大咖说*计算讲谈社|三星堆奇幻之旅:只有云计算才能带来的体验
- [training Day2] cinema ticket [combinatorics] [Cartland number]
- Rotation in ue4/5: three Euler angles picth, yaw, roll and frotator
- 从IT研发人员离职工作交接想到的
- AutoJs学习-应用列表
- How to set up domain name resolution?
- Graphic array calculation module numpy (trigonometric function, rounding function, converting radian to angle, statistical analysis function, median, array sorting, argsort(), lexport())
- ELK集群部署(二)之部署kibana
- What does SPK interface mean
- FPGA 20个例程篇:8.SD卡任意地址的读写
猜你喜欢

C language under custom type (enumeration, Union)

Web page making (II)

7.13学习记录

洞悉数据库迷局,2022金仓创新产品发布会召开

Principle analysis of Rex engine of osgearth (one, two, eight) Rex engine and layer projection and their relationship
![[prefix and difference]](/img/5b/ecf1a2ab1aad950d73430cc766b8cd.png)
[prefix and difference]

#kubeadm安装Kubernetes 1.15最佳实践#

基于多尺度残差密集块和块连接级联U-Net的真实图像去噪

Solution to slow running card of VMware virtual machine

大咖说*计算讲谈社|三星堆奇幻之旅:只有云计算才能带来的体验
随机推荐
社交网络的充分去中心化
Example of declarative transaction management
RSS上手教程:聚合自己的信息收集渠道,RSSHub、FreshRSS、NetNewsWire
指定 TLS 1.3 和 Ciphers 以提升安全性及性能
465-剑指offer(53-I、53-II、04、50)
Enable remote rsyslog logging service
面试问到加密接口 如何测试 怎么解密 该怎么回答呢
数据库系统原理与应用教程(021)—— MySQL 的数据库操作
Finding palindrome prime number in C language
ARTS_202207W1
spk接口指的是什么
二分(二分答案)问题合集
uniapp扫码原生插件(Google MLKit、zxing;支持同时扫多个码)
Sword finger offer 46: Translate numbers into strings
VR (I) ATW ASW
再次了解max_allowed_packet
464 sword finger offer (35, 05, 58, 03)
Apache stress testing tool AB, with post parameter and token request
APISIX 如何与 Hydra 集成,搭建集中认证网关助力企业安全
面试秘籍大放送,编测编学独家秘籍遭外泄?!