Blockchain By Example
上QQ阅读APP看书,第一时间看更新

Ether and gas

Like bitcoin, the Ethereum network has a built-in cryptocurrency, called ether. In addition to operating as a digital currency for payment, ether is used in Ethereum's pricing mechanism for running DApps on the system. Ethereum isn't a free network; you have to pay in ether, whether for transaction fees, or for smart contract deployment or execution. The protocol defines the cost for each computation in a dedicated unit called gas, and the total cost is paid, in order to incentivize miners and avoid denial of service attacks. We will look at the relationship between ether and gas in the next sections.