Spedn

Smart Contracts for Electronic Cash

Spedn is a high level smart contracts programming language for electronic cash.
It compiles to Script dialects in eCash, Bitcoin Cash, Lotus and Bitcoin.
It is designed for explicitness and safety.

Learn Support Contribute
// Example
contract Bet(PubKey alice, PubKey bob, PubKey oracle) {
  challenge aliceWins(Sig sig, DataSig oracleSig, [byte] nonce) { 
      verify checkSig(sig, alice);
      verify checkDataSig(oracleSig, sha256("Alice wins" . nonce), oracle);
  }
  challenge bobWins(Sig sig, DataSig oracleSig, [byte] nonce) { 
    verify checkSig(sig, bob);
    verify checkDataSig(oracleSig, sha256("Bob wins" . nonce), oracle);
  }
}

Reasons Why People Love Spedn

Static typechecking
detects many errors at compile time
Explicitness
no guessing what the expression is supposed to return
Pure functions
free of side effects, the common source of bugs
Curly braces
familiar syntax like in C#, Dart or Rust

Resources

Support