Skip to content

Instantly share code, notes, and snippets.

View neizod's full-sized avatar
📚
phd completed, seeking my new goal in life

Nattawut Phetmak neizod

📚
phd completed, seeking my new goal in life
View GitHub Profile
@neizod
neizod / LICENSE.txt
Created February 21, 2012 01:58 — forked from Python1Liners/LICENSE.txt
Random Separate Element into 2 Lists
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2012 Nattawut Phetmak <http://about.me/neizod>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@neizod
neizod / LICENSE.txt
Created February 21, 2012 21:36 — forked from Python1Liners/LICENSE.txt
Store Credit
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2012 Nattawut Phetmak <http://about.me/neizod>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@neizod
neizod / LICENSE.txt
Created February 26, 2012 21:16 — forked from Python1Liners/LICENSE.txt
Quicksort
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2012 Nattawut Phetmak <http://about.me/neizod>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@neizod
neizod / LICENSE.txt
Created February 27, 2012 18:17 — forked from Python1Liners/LICENSE.txt
Stockbroker
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2012 Nattawut Phetmak <http://about.me/neizod>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@neizod
neizod / LICENSE.txt
Last active April 27, 2019 07:32 — forked from 140bytes/LICENSE.txt
Fibonacci (Recursive Lambda)
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2012 Nattawut Phetmak <http://about.me/neizod>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@neizod
neizod / a.py
Created May 5, 2012 18:33
[CodeJam] Safety in Numbers
for t in range(int(input())):
n, *points = [int(v) for v in input().split()]
x = sum(points)
avg = x * 2 / n
nomore = [p > avg for p in points]
if any(nomore):
n = sum(not b for b in nomore)
over = sum(p * b for p, b in zip(points, nomore))
@neizod
neizod / sourceslist.out
Created May 18, 2012 13:49
cat sourceslist
deb http://packages.linuxmint.com/ lisa main upstream import
deb http://archive.ubuntu.com/ubuntu/ oneiric main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu/ oneiric-updates main restricted universe multiverse
deb http://security.ubuntu.com/ubuntu/ oneiric-security main restricted universe multiverse
deb http://archive.canonical.com/ubuntu/ oneiric partner
deb http://packages.medibuntu.org/ oneiric free non-free
#deb http://archive.getdeb.net/ubuntu oneiric-getdeb apps
#deb http://archive.getdeb.net/ubuntu oneiric-getdeb games
@neizod
neizod / README.md
Created June 14, 2012 15:52
[Blockly] Quicksort - Recursive

Quicksort

Since Blockly doesn't accept function's argument & every variables is global. So I made a recursive stack just for this.

See the picture or copy this xml code and paste into XML tab in this page to see live demo yourself.

May the code be with you. :3

@neizod
neizod / letex_logo.tex
Created June 26, 2012 12:31
Redefine \LaTeX with LaTeX.
\documentclass{article}
\usepackage{relsize}
\newcommand{\myLaTeX}{%
L%
\kern-.36em \lower-.47ex \hbox{\smaller{\smaller{A}}}%
\kern-.15em T%
\kern-.16em \lower+.51ex \hbox{E}%
\kern-.27ex X%
}
@neizod
neizod / LICENSE.txt
Created July 28, 2012 15:53 — forked from Python1Liners/LICENSE.txt
Letter A
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2012 Nattawut Phetmak <http://about.me/neizod>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE