0

Solidity: Smart Contracts.

Smart contracts are at the heart of Decentralized Applications (DApps for short), these are the kinds of applications made possible through the Blockchain technology and yes, cryptocurrencies are only but one of the multiple usages of this technology. The ability to support and run decentralized applications through smart contracts is actually the true power of this technology, here we will talk about smart contracts as implemented in the Ethereum blockchain.

Smart contracts are pieces of software (or applications) deployed and running on a blockchain, in the Ethereum blockchain they govern the behavior of accounts. Smart contracts can be written in several different languages, however, Solidity is the most popular programming language used for developing DApps these days.

Solidity is an object-oriented, high-level language for implementing smart contracts. [1].

In general, Solidity:

  1. Is a curly-bracket language.
  2. Is heavily influenced by C++, Python and JavaScript.
  3. Was designed to target the Ethereum Virtual Machine (EVM).
  4. Is statically typed.
  5. Supports inheritance.

Another important feature of smart contracts is that, once they are deployed into a blockchain, they cannot be altered or updated, in other words they are immutable, which makes it really important to get the contract right before deploying it (there are coding patterns such as a the proxy contract that can be utilized to somehow overcome this restrictions through inheritance, but this is a topic for a different day).

I’ve written a little on blockchain and hashes in Understanding hashes and blockchains, as well as a couple more articles for understanding the true power of blockchain in What are Smart Contracts? [The true power of blockchain] – Part 1 and Writing your first Smart Contract. [The true power of blockchain] – Part 2.

In this series of articles we will cover the basics of the Solidity programming language and the most important concepts you need to be aware of. Up next we will discuss about the Basic Smart Contract Structure and we will do an initial line by line analysis.



Next >>