type below:
brew update
brew install redis
To have launchd start redis now and restart at login:
brew services start redis
// SPDX-License-Identifier: GPL-3.0-or-later | |
pragma solidity >=0.8.4; | |
/// @notice Simple gas-optimized multi-signature contract. | |
contract Multisig { | |
event Propose(address indexed proposer, uint256 indexed proposal); | |
event Sign(address indexed signer, uint256 indexed proposal); | |
event Execute(uint256 indexed proposal); | |
error NotSigner(); |
type below:
brew update
brew install redis
To have launchd start redis now and restart at login:
brew services start redis
// Run this in the F12 javascript console in chrome | |
// if a redirect happens, the page will pause | |
// this helps because chrome's network tab's | |
// "preserve log" seems to technically preserve the log | |
// but you can't actually LOOK at it... | |
// also the "replay xhr" feature does not work after reload | |
// even if you "preserve log". | |
window.addEventListener("beforeunload", function() { debugger; }, false) |
// Lambda S3 Zipper | |
// http://amiantos.net/zip-multiple-files-on-aws-s3/ | |
// | |
// Accepts a bundle of data in the format... | |
// { | |
// "bucket": "your-bucket", | |
// "destination_key": "zips/test.zip", | |
// "files": [ | |
// { | |
// "uri": "...", (options: S3 file key or URL) |
pragma solidity 0.5.2; | |
pragma experimental ABIEncoderV2; | |
import {EthereumRuntime} from "./EthereumRuntime.sol"; | |
import {EVMMemory} from "./EVMMemory.slb"; | |
import {MerkleProof} from "./MerkleProof.slb"; | |
contract CompactMemoryProofsMock { | |
using EVMMemory for EVMMemory.Memory; |
contract Contract { | |
function main() { | |
memory[0x40:0x60] = 0x80; | |
if(msg.data.length < 0x04) { revert(memory[0x00:0x00]); } | |
var var0 = msg.data[0x00:0x20] / 0x0100000000000000000000000000000000000000000000000000000000; | |
if(var0 == 0x025e7c27) { | |
var var1 = msg.value; |
pragma solidity ^0.4.25; | |
import "https://github.com/OpenZeppelin/openzeppelin-solidity/contracts/payment/escrow/ConditionalEscrow.sol"; | |
contract ConditionalTradeEscrow is ConditionalEscrow{ | |
uint private _nConditions; | |
mapping(address => uint) private _buyerConditions; | |
bool private _sellerApproval; | |
constructor(uint _n) public{ |
import numpy as np | |
from data_prep import features, targets, features_test, targets_test | |
np.random.seed(42) | |
def sigmoid(x): | |
""" | |
Calculate sigmoid | |
""" | |
return 1 / (1 + np.exp(-x)) |
import numpy as np | |
def sigmoid(x): | |
""" | |
Calculate sigmoid | |
""" | |
return 1 / (1 + np.exp(-x)) | |
import numpy as np | |
def sigmoid(x): | |
""" | |
Calculate sigmoid | |
""" | |
return 1 / (1 + np.exp(-x)) | |