Skip to content

Instantly share code, notes, and snippets.

View scyclow's full-sized avatar
💭
$$$

Steve Pikelny scyclow

💭
$$$
View GitHub Profile
// The previous two files should give you an object, `typePoints`
// for this to work, you need to delete the last point of each contour
function drawChar(char, x, y, s, stroke_, fill_) {
push()
translate(x-25*s, y+40*s)
scale(s)
stroke(stroke_)
fill(fill_||stroke_)
let contourOpen = false
@scyclow
scyclow / pg-schema.sql
Last active December 29, 2018 01:53
postgraphile test
begin;
drop schema friendworld cascade;
drop schema friendworld_private cascade;
drop domain username_domain;
drop role friendworld_root;
drop role friendworld_anonymous;
drop role friendworld_user;
create extension if not exists "uuid-ossp";
@scyclow
scyclow / Flexible.sol
Last active March 24, 2018 21:13
Writing flexible contracts
import "FeatureContract.sol"
contract CoreContract {
FeatureContract public featureContract;
address public CEO;
function FastCashMoneyPlusPermissions(address _featureContractAddress) public {
featureContract = FeatureContract(_featureContractAddress);
}
@scyclow
scyclow / FCMP4.sol
Last active March 24, 2018 21:12
Adding Permissions
pragma solidity ^0.4.17;
/*
Copyright 2017, FastCashMoneyPlus.biz
This contract is for educational purposes only, and is presented WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED.
*/
contract FastCashMoneyPlusPermissions {
address public centralBanker;
@scyclow
scyclow / FCMP3.sol
Last active March 24, 2018 21:10
ERC-20 Compliance
pragma solidity ^0.4.17;
/*
Copyright 2017, FastCashMoneyPlus.biz
This contract is for educational purposes only, and is presented WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED.
*/
contract FastCashMoneyPlus {
uint public totalSupply;
uint256 public fastCashBank;
@scyclow
scyclow / FCMP2.sol
Last active March 24, 2018 21:11
Buying Token contract
pragma solidity ^0.4.17;
/*
Copyright 2017, FastCashMoneyPlus.biz
This contract is for educational purposes only, and is presented WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED.
*/
contract FastCashMoneyPlus {
uint public totalSupply;
uint256 public fastCashBank;
@scyclow
scyclow / FCMP1.sol
Last active March 18, 2018 19:15
Hello World Contract
pragma solidity ^0.4.17;
/*
Copyright 2017, FastCashMoneyPlus.biz
This contract is for educational purposes only, and is presented WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED.
*/
contract FastCashMoneyPlus {
uint public totalSupply;
uint256 public fastCashBank;
@scyclow
scyclow / FastCashMoneyPlus.sol
Created March 17, 2018 18:29
FastCashMoneyPlus FULL CONTRACT
pragma solidity ^0.4.17;
/*
Copyright 2017, FastCashMoneyPlus.biz
This is highly propriatary software. Under no circumstances is anyone, except for employees of
FastCashMoneyPlus.biz, authorized to modify, distribute, use, or otherwise profit from these
contracts. Anyone attempting to do so will be prosecuted under the full extent of the law.
*/
const expressionStart = (token) => token[0] === '(';
const expressionEnd = (token) => token[token.length - 1] === ')';
function evaluate(token) {
let numbered = Number(token);
if (token === 'true') {
return true;
// Lisp parser. Written in JavaScript/ES6.
const expressionStart = (token) => token[0] === '(';
const expressionEnd = (token) => token[token.length - 1] === ')';
function evaluate(token) {
let numbered = Number(token);
if (token === 'true') {