I hereby claim:
- I am alep on github.
- I am alep (https://keybase.io/alep) on keybase.
- I have a public key ASB5OL0YFwaQhbCxoVZbHr9cUkILo_YgfXg2isMxUQdl7go
To claim this, I am signing this object:
##TCP FLAGS## | |
Unskilled Attackers Pester Real Security Folks | |
============================================== | |
TCPDUMP FLAGS | |
Unskilled = URG = (Not Displayed in Flag Field, Displayed elsewhere) | |
Attackers = ACK = (Not Displayed in Flag Field, Displayed elsewhere) | |
Pester = PSH = [P] (Push Data) | |
Real = RST = [R] (Reset Connection) | |
Security = SYN = [S] (Start Connection) |
So, let’s flip a coin: if it’s heads, play a drum, if it’s tails, play a cymbal. Easy. We can emulate a coin flip with our one_in function (introduced in the section on randomness) specifying a probability of 1 in 2: one_in(2). We can then use the result of this to decide between two pieces of code, the code to play the drum and the code to play the cymbal: | |
loop do | |
if one_in(2) | |
sample :drum_heavy_kick | |
else | |
sample :drum_cymbal_closed | |
end | |
I hereby claim:
To claim this, I am signing this object:
#python3 | |
import numpy as np | |
from itertools import product | |
from scipy.spatial.distance import euclidean | |
coords = [(35.0456, -85.2672), | |
(35.1174, -89.9711), | |
(35.9728, -83.9422), | |
(36.1667, -86.7833)] |
package main | |
import ( | |
"fmt" | |
) | |
type Fetcher interface { | |
// Fetch returns the body of URL and | |
// a slice of URLs found on that page. | |
Fetch(url string) (body string, urls []string, err error) |
[Desktop Entry] | |
Version=24.5 | |
Name=Emacs | |
Exec=env UBUNTU_MENUPROXY=0 /usr/local/bin/emacs-24.5 | |
Terminal=false | |
Icon=/usr/local/share/icons/hicolor/128x128/apps/emacs.png | |
Type=Application | |
Categories=IDE | |
X-Ayatana-Desktop-Shortcuts=NewWindow | |
[NewWindow Shortcut Group] |
(by @andrestaltz)
So you're curious in learning this new thing called Reactive Programming, particularly its variant comprising of Rx, Bacon.js, RAC, and others.
Learning it is hard, even harder by the lack of good material. When I started, I tried looking for tutorials. I found only a handful of practical guides, but they just scratched the surface and never tackled the challenge of building the whole architecture around it. Library documentations often don't help when you're trying to understand some function. I mean, honestly, look at this:
Rx.Observable.prototype.flatMapLatest(selector, [thisArg])
Projects each element of an observable sequence into a new sequence of observable sequences by incorporating the element's index and then transforms an observable sequence of observable sequences into an observable sequence producing values only from the most recent observable sequence.
In [1]: %load test.py | |
In [2]: import pandas as pd | |
import numpy as np | |
frame = pd.read_csv("table.csv", engine="python", parse_dates=['since']) | |
print frame | |
d = pd.pivot_table(frame, index=pd.TimeGrouper(key='since', freq='1d'), values=["value"], columns=['id'], aggfunc=np.sum, fill_value=0) | |
print d | |
print "^that is not what I expected" |