{{ message }}

Instantly share code, notes, and snippets.

💤
procrastinating

# Nattawut Phetmak neizod

💤
procrastinating
Created Mar 29, 2014
[quick-dirty] html+js hack for cracking the substitution encryption.
View freq.html


encrypted sentence

decrypted sentence

Last active Aug 29, 2015
Sorting Algorithms
View bubble.cpp
 #include using namespace std; int arr[] = {2,5,3,9,1,0,7,4,8,6}; void show(int i=-1) { for (int k=0; k<10; k++) { if (i-1 == k) cout << "\x1b[37;1m"; if (i == k) cout << "\x1b[31;1m"; cout << arr[k];
Last active Aug 29, 2015
k-means clustering.
View kmeans.py
 #!/usr/bin/env python3 import sys from itertools import count class Point(object): def __init__(self, pp): self.x, self.y = pp
Last active Aug 29, 2015
Pachinko -- https://icpc.kattis.com/problems/pachinko
View pachinko.py
 #!/usr/bin/env python3 from numpy import matrix, zeros class RandomWalk(object): limpow = 10**9 offset = [(0,-1), (0,1), (-1,0), (1,0)]
Created May 11, 2015
test nbviewer
View it.ipynb
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Created Sep 28, 2011
Hello Gist!
View hellgist.b
 ++++++++++[>+++++++>++++++++++>+++>+<<<<-]>++.>+.+++++++..+++.>++.<<-.>------.++++++++++.+.>+.>.
Created Oct 2, 2011 — forked from 140bytes/LICENSE.txt
GCD - recursive style, variable arguments.