Virtual Machine - runtime environment “computer running on computer” e.g. JVM allows interoperability (cross-platform) has it’s own bytecode (rather than assembly). An intermediary language specifically for smart contracts has its own instrucation set big endian ordering (most sig byte at smallest memory) ROM not RAM, not Von Neumann stack based architecture (as opposed to register) has memory(volatile) and storage(non-volatile)
Language that targets the EVM.
Basic template pragma solidity __version__ contract NameOfContract { // state variables // public makes accessible from other contracts (like a global variable on the chain) // event can react from a trigger // error provide info on why fail // functions // fallback function if anything is called } General constructor called at beginning msg is a global variable Can check whether msg.
lazy, atomic/stateless, strong typing, pure (no side effects)
Some pros
concurrency faster What are haskell bindings?
What are monads?
forcing side effects into haskell What is haskell better for?
Built with pytorch backend Usually involves specifying a generative process Usually either use Stochastic Variational Inference (SVI) optimization methods or Monte Carlo Markov Chain (MCMC) sampling methods For SVI Define a model and a guide (variational distribution) guides define where the parameters are to be learnt Example model and guide code
def reverseList(self, head: ListNode) -> ListNode: current = head while (current and current.next): next = current.next current.next = next.next next.next = head head = next return head This is a real basic problem, but it can be tricky.
tf.session initiates a tf graph object. Use global variable initializer with it - with tf.Session() as sess: sess.run(tf.global_variables_initializer()) ‘tf.placeholder’ Inputs to be fed in ‘tf.
Learn x in y style
(* This is a comment *) (* Inductive type, enumerated finite *) (* Each item called a constructor *) Inductive day : Type := | monday | tuesday.