What is Solidity?

Solidity is an object-oriented, high-level programming language for implementing smart contracts. It allows to write programs that manage the behavior of accounts on the blockchain network. It is statically typed, supports contract inheritance, and has many built-in Contract Libraries. Solidity is similar to programming languages such as C++, Python, and JavaScript.

It consists of:

  • Variables

  • Operators

  • Loops

  • Conditionals

  • Modifiers

  • Functions

  • Objects and their types

  • Events

  • Interfaces

  • And executes monetary transactions.

Before moving on to coding with Solidity, it is important to become familiar with the mental models of the blockchain – these are important because of the contrast between a blockchain application architecture and a common web application architecture. Where we want to go is Web 3.0, where servers and databases are as distributed as clients. In other words, clients can also act as servers or databases, or both (i.e. peer-to-peer). In many-to-many relationships at all levels of the stack, there is no concentration of control and no single point of failure. The network is maximally distributed.

Essentially, the following points should always be kept in mind:

  • Memory is limited - each memory item requires all nodes in the blockchain to validate and store that item.

  • Computational complexity is limited.

  • Data is free to read.

  • Every write has a cost - you pay it in ether. The cost is measured in gas.

Last updated