Skip to content

Instantly share code, notes, and snippets.

<!doctype html>
<meta charset='utf-8'>
<script src='example.js'></script>
<button type='button' class='browser-style' id='set'>Set</button>
<button type='button' class='browser-style' id='get'>Get</button>
<p id='output'></p>
@psimonyi
psimonyi / forkbomb.c
Created September 17, 2014 21:12
Forkbomb testing service
#include <unistd.h>
int main() {
while (1) fork();
}
@psimonyi
psimonyi / binclock.py
Created June 2, 2012 01:38
A Python binary clock
#!/usr/bin/env python3
# Peter Simonyi 1 June 2012
'''A binary clock: prints the current time (HHMMSS) in binary-coded decimal.
Each BCD digit takes one column; least-significant bits are at the bottom.
Example: at 21:14:59 (local time):
000001
000110
100000
011011
@psimonyi
psimonyi / binclock.js
Created May 29, 2012 04:35 — forked from cdelahousse/binclock.js
JS Binary Clock
// vim: shiftwidth=8 noexpandtab softtabstop=0
/*
* Christian Delahousse
* Binary Clock
* May 27,2012
* Edited by Peter Simonyi 29 May 2012
*/
'use strict';