Blockchain is known to be used for store of value and as a financial platform (like a bank). Smart contracts are the answer to the question of what else can it do?
The answer, it turns out, is just about anything. Smart contracts are built using generalized logic and thus can perform any computationally feasible operation based on the inputs and modify its state and transfer value from its funds. A blockchain’s state can be more than just account balances. Smart contracts are user created rules that can define, update and change their own variables. The logic itself is ownerless and verifiable by anyone once it’s been deployed onto the blockchain.
The availability of smart contracts is a game changer for many industries, as they are automatic and verifiably trustless, thus offering significant cost-saving potential.
Smart contracts are written in a flexible and powerful programming language, enabling virtually any computationally feasible logic.
Anyone can audit the code and, once deployed, the code is immutable and can only do what its logic defines.
Smart contracts significantly reduces needs for labor, business processes, and paper trails–enabling the potential for a complete footprint-free system.
Anyone can use or deploy a smart contract with no restrictions.
User established EVM standards allow smart contracts to easily interoperate with each other, creating a collaborative ecosystem of DApps.
Trustless logic is used to represent value of digital objects and variety of interactions, from direct transfers to more complex arrangements.
Case Study: Smart Contracts Lottery
Governments may use lottery to allocate public resources, including and not limited to: seats in popular schools, and quotas to purchase subsidized housing.
However, as the system is centralized, citizens worry about “fixed results”–a criticism hard to defend against. To solve this problem, ThunderCore worked with a city government team to put the entire lottery system into a smart contract! The contract is trustless, and its rules for lottery are auditable by anyone.
The first problem we focused on is seats for overfilled schools:
Once that block has passed, the government will reveal their initial random number along with the block hash to the smart contract.
The contract takes both the hash and the random number and selects the winners from all of the participants.
Transactions for applying and choosing winners are efficiently handled through the smart contract and the entire process is fair and verifiable.