> eth.getBalance(eth.accounts[0]) web
160000000000000000000spa
getBalance()返回值的單位是wei,wei是以太幣的最小單位,1個以太幣=10的18次方個wei。get
web3.fromWei()im
要查看有多少個以太幣,能夠用web3.fromWei()將返回值換算成以太幣:img
> web3.fromWei(eth.getBalance(eth.accounts[0]),'ether')co