I was reading about the smart contract and I'm able to create the smart contract but I didn't know why the smart contract is used? When I did search on google about this, I understood following -

  • New language 'solidity' used for creating the smart contract.

  • A smart contract is secure and can't be updated after deploying.

  • A smart contract is nothing but a set of functions which automates the process.

  • After deploying it into the blockchain network, will get the address of that contract. By importing this address, we can able to access its methods.

  • A smart contract doesn't store the data, We need to create the logic accordingly to store the data in DB.

But wait, we can achieve above same points using the set of programs called 'packages'. Why not we use the following -

  • Create one package which has all set of functions. (the same we've written in the smart contract using solidity)

  • We can make this package as private. (Only some organization have access to this)

  • We can add the extra security layer so that malicious user does not have the access to that code.

lastly, my main concern is why the smart contract is used? despite we can implement the same logic using the package (as described above)

  • 2
    Sorry, what is "the set of programs called 'packages'"?
    – TorstenS
    May 25, 2018 at 12:07

2 Answers 2


Through human history people has come with new ideas and baptize these ideas with names. "Smart contract" is a name for one idea. It is nothing but a piece of code ( in this case running in a decentralized network). There is nothing particular (fundamentally speaking) to the "smart contract", compared with any other scrypt.

A lot of people will say that the smart contracts are not smart, but on the context of a network that has only capability to send basic transactions, to have a tool that can process input data and provide an output based in some type of logic, could be considered an "smart" tool.

So you can think about the "smart contract" as a piece of code.

We can add the extra security layer so that malicious user does not have the access to that code

But in a trust-less network, like Ethereum and bitcoin you want everyone have access to the code (so that you do not have to trust the good intentions of people), although you do not want people to temper with it. These are achieved in Ethereum already.

Hope this helps


The difference is a developer or owner can arbitrarily change the code or the state (database) of a centralized system using centralized software.

Use a smart contract in the case that you want to data itself to rise to the level of an inarguable fact. That is, new data enters the system only through channels defined in the smart contract. Inversely, the mere existence of data/state in a smart contract can serve as proof that the process prescribed by the smart contract must have occurred.

An example is "tokens". More broadly, crypto-currencies. These are database states and processes that are not subject to arbitrary interference by authoritative actors, by design. As a proof-of-concept for blockchain and proof-of-work, I would argue Bitcoin and Ethereum have done quite well.

Ethereum does something entirely new that possibly fits into an overall architecture.

In case it helps, a blockchain can establish a set of invariants for an application and people can see that violations of those invariants will not be possible.

Hope it helps.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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