I did the same thing.
It turns out that philosophy and programming are distressfully similar. You build a structure out of logic and feel proud of yourself until somebody finds a bug, and then you scramble around trying to reassemble your logic structure so it doesn't have the bug. The main difference is that you can test a program, so the turnaround time is measured in minutes rather than, in some cases, centuries.