Today’s Solidity Lesson : A Simple Smart Contract

http://solidity.readthedocs.io/en/latest/introduction-to-smart-contracts.html#a-simple-smart-contract

Example of coding for simple contract:

Coin.Sent().watch({}, ”, function(error, result) {
if (!error) {
console.log(“Coin transfer: ” + result.args.amount +
” coins were sent from ” + result.args.from +
” to ” + result.args.to + “.”);
console.log(“Balances now:\n” +
“Sender: ” + Coin.balances.call(result.args.from) +
“Receiver: ” + Coin.balances.call(result.args.to));
}
}

And for some supplemental training:
https://dappsforbeginners.wordpress.com/ Dapps for Beginners

https://learnxinyminutes.com/docs/solidity/
Learn X and Y in Minutes
X=Solidity

Leave a Reply

Your email address will not be published. Required fields are marked *