Skip to content

Instantly share code, notes, and snippets.

View bl0ckeduser's full-sized avatar

Gabriel Cormier-Affleck bl0ckeduser

View GitHub Profile
@bl0ckeduser
bl0ckeduser / wannabe-regex-v2.c
Created August 27, 2012 23:41
NFA wannabe regex, with more fixes
/*
* August 27, 2012 error fixes:
*
* Fixed + compilation to work properly with
* proper epsilon nodes. Fixed evaluator infinite
* loop check to work well with this.
* Some comments on the new messy (but better-working)
* + / * nodes/edges.
* (Yeah, I know, it's mostly similar to yesterday).
*/
@bl0ckeduser
bl0ckeduser / wannabe-regex.c
Created August 26, 2012 21:36
NFA wannabe regex, revised
/*
* August 26, 2012 error fixes:
*
* Fixed * compilation to work properly with
* proper epsilon nodes. Fixed evaluator infinite
* loop check to work well with this.
* Removed large stack allocation in main().
*/
/*
@bl0ckeduser
bl0ckeduser / wannabe-regex-v1.c
Created August 25, 2012 20:36
NFA wannabe regex
/*
* Wannabe regex (egrep-style)
* Wannabe automatic regex tokenizer
* Wannabe egrep command (./a.out --wgr 'pattern')
*
* The wannabe egrep can make a picture of the compiled NFA
* this way:
* ./a.out --wgr 'pattern' --pic | pic | troff -ms
*
* Supported 'special' characters:
@bl0ckeduser
bl0ckeduser / chromakeyman2.c
Created July 19, 2012 18:17
ChromakeyMan v2.2
/*
* ChromakeyMan v2.2
* by 'Bl0ckeduser'
*
* A simple chroma-key effect program
*
* Originally written in METAL Basic
* (on Mac OS 9) in 2007-2008 for ad-hoc
* use in a little VFX project.
*
@bl0ckeduser
bl0ckeduser / chromakeyman2.c
Created July 19, 2012 01:21
ChromakeyMan v2.1
/*
* ChromakeyMan v2.1
* by 'Bl0ckeduser'
*
* A simple chroma-key effect program
*
* Originally written in METAL Basic
* (on Mac OS 9) in 2007-2008 for ad-hoc
* use in a little VFX project.
*
@bl0ckeduser
bl0ckeduser / permut.c
Created June 26, 2012 22:18
String permutations
/*
* Print all permutations of a string,
* using a tree-recursive routine. I
* bet there are smart algorithms out
* there that beat this. I did not look
* up an algorithm when writing this.
*
* Bl0ckeduser
* June 26, 2012
*/