1

Why do contracts have an account? I mean, their code is entered to the blockchain and their balance can be computed by previous transactions, so why is there an account of it?

1 Answer 1

2

As you pointed yourself, ethereum contracts have balance, just as regular user accounts (Externally Owned Accounts), so they can store, receive and transfer ether. That fact alone indicates that they need to be an account and not a transaction. Accounts are for storing ether and in case of contract accounts data and logic too, whereas transactions are about sending value or data from one account to another.

You can read more about Ethereum network architecture here: http://ethdocs.org/en/latest/contracts-and-transactions/account-types-gas-and-transactions.html

1
  • I see, so the whole account thing is for balance managing? can't it be calculated via the blockchain?
    – adi
    Apr 19, 2018 at 22:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.