Skip to content

Instantly share code, notes, and snippets.


Hugo hugo-dc

View GitHub Profile
izqui / forwarder.sol
Last active Mar 30, 2019
Very cheap to deploy (66k gas) forwarder contracts that can clone any contract and still have their own storage
View forwarder.sol
// Bytecode origin
// Modified version of Vitalik's
// Credits to Jordi Baylina for this way of deploying contracts
// Forwarder is slightly modified to only return 256 bytes (8 normal returns)
// Deployed Factory in Kovan:
// Example of a Forwarder deploy using the Factory:
// Just 66349 gas per contract

Edit 8/14/18: See for more updated information. Much of the links below are still valuable though.


This guide is intended to provide resources for those wanting to help test Metropolis EIPs. The CPP team is currently in the middle of a migration from EthDocs to a documentation site that is more dedicated to CPP-Ethereum so the documentation on creating tests for Ethereum using testeth is scattered. Everything you will need to get started should be compiled below.

Suggested skill sets needed to create and run tests

  1. Ability to compile/build testeth and LLL compiler or run a docker file.
  2. Ability to [understand the LLL Ethereum language](
axic / ecverify.sol
Last active Nov 19, 2020
Ethereum ECVerify
View ecverify.sol
// The new assembly support in Solidity makes writing helpers easy.
// Many have complained how complex it is to use `ecrecover`, especially in conjunction
// with the `eth_sign` RPC call. Here is a helper, which makes that a matter of a single call.
// Sample input parameters:
// (with v=0)
// "0x47173285a8d7341e5e972fc677286384f802f8ef42a5ec5f03bbfa254cb01fad",
// "0xaca7da997ad177f040240cdccf6905b71ab16b74434388c3a72f34fd25d6439346b2bac274ff29b48b3ea6e2d04c1336eaceafda3c53ab483fc3ff12fac3ebf200",
// "0x0e5cb767cce09a7f3ca594df118aa519be5e2b5a"
bishboria /
Last active Feb 7, 2021
Springer made a bunch of books available for free, these were the direct links
chubas /
Last active Dec 10, 2015
Cards Against Slack

GDLJS Monthly Challende #2 - Cards Against Slack


The task for this month is to create a simple Hubot script to play Cards Against Humanity on Slack. Yay productivity!


The rules for the challenge will be the minimum set of rules of the game (full rules), only using the house rule of public voting (God is Dead rule)

artjomb /
Last active Feb 4, 2021
List of Pairing Libraries

Pairings can be used for all kinds of advanced cryptographic schemes such as Encryption (Identity-based, Attribute-based, Predicate-based, etc.), Signatures, Zero-Knowledge Proofs, etc. It is in no particular order.


Provides multiple types of Elliptic Curve groups with appropriate pairings on top of them. Code repository resides here.

License: LGPL
Language: C
Thesis: On the Implementation of Pairing-Based Cryptography by Ben Lynn (2007)

burtonsamograd / nock.lisp
Created Oct 9, 2015
A Nock Interpreter and Compiler in Common Lisp #Urbit
View nock.lisp
;; A nock interpreter
(defun tar (a f)
(labels ((fas (b a)
(declare (integer b))
((= b 1) a)
((= b 2) (car a))
((= b 3) (cdr a))
((evenp b) (car (fas (/ b 2) a)))
((oddp b) (cdr (fas (/ (1- (the integer b)) 2) a))))))
taksuyu /
Last active Oct 30, 2017
A list of material that helped me learn the lens package.

Learning Lens

I tend to focus on core concepts quite a bit more than actual examples, so that the fundamental understanding of what the examples are trying to teach me is building on skills I already have just haven't figured out how to use yet.

tl;dr Your mileage may vary. I learn kind of counterintuitively for others.

Since this seemed to be popular, I decided to make a repository for content about haskell topics that you can find here new materials for lens will be put here

dvdsgl / Monads for a C#
Last active Nov 12, 2020
Monads explained (sort of) to a C# developer
View Monads for a C#

A monad is a fancy word for a generic type of the form MyMonad<T> (a generic type of arity 1).

A monad is special because it adds 'special powers' to the T that it wraps. These 'special powers' won't sound very special to an imperative programmer, so you have to squint to see them but bear with me.

  • IEnumerable<T> is a monad that gives values of type T the special power of nondeterminism, or the ability to 'be' multiple values at once.
  • Nullable<T> is a monad that gives values of type T the special power of nullability, or the ability to be absent.
  • Task<T> is a monad that gives values of type T the special power of asynchronicity, or the ability to be used before they are computed.

The trick with monads comes when you want to play with the T values, because they are inside another type. C# introduced language changes to make dealing with values inside these monads easier:

zachhanson94 / LiveCoding Instructions
Created Jul 11, 2015
Instructions to setup external streaming and chatting for streams
View LiveCoding Instructions
// ************** Instructions for connecting to the LiveCoding chatrooms from a 3rd party application. ****************
Step 1a (Ubuntu/ any OS with aptitude (aka apt-get)) :
sudo apt-add-repository ppa:rsrchboy/profanity && sudo apt-get update
apt-get install profanity
Step 1b (OSX w/ homebrew):
$ brew install profanity