I hereby claim:
- I am restuta on github.
- I am restuta (https://keybase.io/restuta) on keybase.
- I have a public key ASDPbUkAXpS7m7MrLZeRf83VBDVZqJaQe6ycN-pfoiJSCQo
To claim this, I am signing this object:
import { | |
percentAmount, | |
generateSigner, | |
signerIdentity, | |
createSignerFromKeypair, | |
} from '@metaplex-foundation/umi'; | |
import { mplToolbox, setComputeUnitPrice } from '@metaplex-foundation/mpl-toolbox'; | |
import { | |
TokenStandard, | |
createAndMint, |
import * as O from 'rxjs'; | |
const delay = ms => new Promise((resolve) => setTimeout(() => resolve(ms), ms)); | |
O.from([1,2,3]) | |
.pipe( | |
O.map(x => O.defer(() => delay(1000))), | |
O.mergeAll(1) | |
).subscribe(x => console.log(x)) |
I hereby claim:
To claim this, I am signing this object:
// map, reduce, pipe in 3 minutes | |
const reduce = (reducer, defaultAcc, list) => { | |
let acc = defaultAcc | |
for(let item of list) { | |
acc = reducer(acc, item) | |
} | |
return acc |
/** | |
* author: tourist | |
* created: 08.08.2020 17:11:40 | |
**/ | |
#include <bits/stdc++.h> | |
using namespace std; | |
template <typename T> | |
class graph { |
// z-score | |
const { mean, deviation } = require('d3-array') | |
const zscore = input => { | |
const arrMean = mean(input) | |
// here the n-1 : http://duramecho.com/Misc/WhyMinusOneInSd.html | |
const arrDeviation = deviation(input) | |
return input.map(i => ({ | |
zscore: (i - arrMean) / arrDeviation, | |
item: i, |
const R = require('ramda') | |
const numbers = [1, 2, 8, 9] | |
const transducer = R.compose( | |
R.filter(x => { | |
console.log('filter', x) | |
return x > 3 | |
}), | |
R.map(x => { |
import cleanStack from 'clean-stack'; | |
// dims non-useful log lines in stack traces | |
const neatStack = (colorize, stack) => { | |
// add parts of stack trace lines here that should be ignored | |
const regexParts = [ | |
'(node_modules)', | |
'(WEBPACK_IMPORTED)', | |
'(next_tick.js)', | |
'(domain.js)', |
Sometimes it's useful to know what IP ranges our servers are operating in. Since we run on Heroku, it's a little complicated. However, Heroku runs on AWS, which has this page dedicated to IP Ranges by Region.
Heroku recommends using this to identify which region are bing in use. If dynos are run in common spaces in US region, we can look up information about this region using Heroku's API:
using httpie:
http https://api.heroku.com/regions/us "Accept:application/vnd.heroku+json; version=3"