Really its the part of crypto that I'm most excited about.what is a smart contract?
So a blockchain is just a history of transactions that exists in the memory of all the computers working in it, a history that can be accessed by anyone. Differences here and there across blockchains, but that is the premise: a ledger in which there is no central entity that everyone else has to trust is acting in their interest.
So lets say there are a million active addresses on a blockchain, which means each one is being used, lets say by one person each. Each person has one address associated with them, and each address as a balance associated with it.
When you "send" Bitcoin, you just submit a change to the ledger in which the balance associated with your wallet address changes, as does the balance associated with the wallet address of the recipient. Its just data shifting around, one massive sequence of 1's and 0's changing to another massive sequence of 1's and 0's. Every change included many transactions, so its not just one transaction per iteration.
Because this is all code, it can be algorithmically manipulated. Wallet balance is pure data, and we merely associate an abstract value with this data. Smart contracts are algorithms that can be written to automatically and rapidly change balance data in very complex and conditional ways.
If you make a bet with someone that it will rain where you live this time next week, and you write a smart contract that draws from weather data from sensors in your area, you no longer need to rely on your friend choosing to fulfill their financial obligation. If it rains, you receive the money.
edit: that is, balance of your address has increased and that of your friend's has decreased.