0x Doc was created to serve technically-savvy users such as market-makers, 0x API integrators, and RFQ providers that want to gain more insight from the on-chain magic that happens in 0x.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def smoSimple(dataIn, classLabels, C, tolerance, maxIter): | |
dataMatrix = mat(dataIn) | |
labelMat = mat(classLabels).T | |
m, n = shape(dataMatrix) | |
alphas = mat(zeros((m,1))) | |
bias = 0 | |
iter = 0 | |
while (iter < maxIter): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pragma solidity ^0.4.0; | |
contract Commitment { | |
enum CommitmentState { OPEN, CLOSED } | |
mapping (address => bool) attendeesRegistered; | |
mapping (address => bool) attendeesRefunded; | |
uint totalDeposited; | |
uint totalGuests; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pragma solidity ^0.4.0; | |
contract Commitment { | |
enum CommitmentState { OPEN, CLOSED } | |
mapping (address => bool) attendeesRegistered; | |
mapping (address => bool) attendeesRefunded; | |
uint totalDeposited; | |
uint totalGuests; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pragma solidity ^0.4.0; | |
contract Ballot { | |
struct Voter { | |
uint weight; | |
bool voted; | |
uint8 vote; | |
address delegate; | |
} | |
struct Proposal { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from typing import Tuple, NamedTuple, List, Optional, Dict | |
class SpendResult(NamedTuple): | |
is_successful: bool | |
remaining_balance: int | |
class Bank(object): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import itertools | |
import sys | |
def non_increasing_range(items, i, j, _c): | |
try: | |
d = _c[(i, j)] | |
return d | |
except KeyError: | |
pass |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//**************************************************************************// | |
// This is a modified version of the Microsoft sample code and loads a mesh.// | |
// it uses the helper class CDXUTSDKMesh, as there is no longer any built in// | |
// support for meshes in DirectX 11. // | |
// // | |
// The CDXUTSDKMesh is NOT DorectX, not is the file format it uses, the // | |
// .sdkmesh, a standard file format. You will hnot find the .sdkmesh format // | |
// outside the MS sample code. Both these things are provided as an entry // | |
// point only. // | |
// // |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"txid": "8608b1ee194cdacbd3b2d1728b4883afe11a76d4a60b3d8d1f36317ccc12d583", | |
"hash": "8608b1ee194cdacbd3b2d1728b4883afe11a76d4a60b3d8d1f36317ccc12d583", | |
"size": 224, | |
"vsize": 224, | |
"version": 2, | |
"locktime": 1488155936, | |
"vin": [ | |
{ | |
"txid": "a7681326607bbb94026fca9f21563b2c1418c22b8e39638f7910e338915ead46", |
NewerOlder