Mac OS X Logo
Apple User since 1990
Projects Writings Image Gallery Code Flying Toasters

Code

Sudoku Program

Sudoku Code base (Eclipse Java project). Unfortunately I am too lazy to make an applet or even compile it for you. Do it yourself!

To prove I'm "with the times" I made a sudoku program. I experimented with the UI quite a bit to try to facilitate the way I solve them on paper. Set a number to a box by left clicking on the number or typing the number. Remove a posibility by right clicking on it in the box.

The computer does thes simplest deductions for you. If there's only one posibility for a box, it chooses it. If there's only one box remaining for a particular number within a group, it chooses it. These two simplifications are enough for a depressingly large number of squares, and even completely solve all but the hardest puzzles. Now I feel dumb when I get stuck on a puzzle by hand, since I know I'm just missing something easy.

This is still "incomplete" in the sense that I haven't implemented several features that I thought about. Don't mess up - there's no undo. Also there should be a "solve" button and the autofilling should have some way to turn it off. However, I am quite bored with sudoku and unlikely to continue. I've heard there's a clever, formal way of solving this with sets. That might be worth implementing.

PHP cookies.

Cookies are suprisingly easy in php. Heres some code I wrote to read and write cookies [read code] [write code]. I hope this doesnt have any kind of security implications - cookies have a bad rap.

animeNameFix [bash Script]

Bittorrents tend to prefer complicated naming schemes for anime files. A typical file will look something like this: [LMF]_Ghost_In_The_Shell_-_05_[7FBF1113].avi. This script takes out the extra stuff, converting it into simple Ghost In The Shell - 05.avi

Cowsay

Cowsay is one of those great programs that everyone should have installed on their linux box, allong with fortune and vim. Heres some extra special extensions I wrote.

quantum7 at qmail dot com
-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GCS d- s++: a--- C++ UB++ P-- L++ E--- W+++ N++++ o-- K- w--
O- M++ V-- PS+ PE- Y+ PGP+ t+ 5 X R !tv b+++ DI++ D+
G-- e* h- r y-
------END GEEK CODE BLOCK------