|
|
July 2008 Blog Posts
Ok, I've been doing the programming quizzes here and have a solution... In Perl:$FILE = "expressions.txt";open(FILE) or die("Could not open expressions file.");foreach $OLINE (<FILE>){ $LINE = $OLINE; if ($LINE =~ m/(^[\]}\)>])|([\[{\(<]$)/) { print "bad : $OLINE" } else { while ($LINE =~ m/(\[\])|({})|(\(\))|(<>)/) { $LINE =~ s/(\[\])|({})|(\(\))|(<>)//g } $strLen = length($LINE); if ($strLen > 1) { print "bad : $OLINE" } else { print "good : $OLINE" } }}And a C# console app to generate the "sample" strings (i.e. the "expressions.txt" file used above):using System;using System.Collections.Generic;using System.Text;namespace ConsoleApplication1{...
Ok, I've done it again. Another Conway's Game of Life, this time in Java: The source code can be had here. It's called Gola (Game Of Life Applet). So, I've quit smoking. I started July 6 at 11:27pm (my last cigarette). It is going much better this time. This is my third time. The first two times I quit for 2+ years each time. I know this time is my final one. Why? I had a "moment" where I just didn't want them anymore. That feeling stayed, even after I failed, so I set a...
Ok, I went and done it...With my inability to purge my rotting brain of Conway's Game of Life, I have produced none-other than a super double-buffered javascript only Conway's Game of Life!Hopefully I can sleep now. Below is it in all it's glory. You can get the javascript to run it here.NOTE: ARRRRRRGGGGHHH!!! Ok, trying to get javascript to run in blogger, but it'll take a little work. Here's so you can see it worksADDENDUM: In Blogspot, IE doesn't like this script so well, nor does Firefox. I've removed it from the page but you can still see it at...
Archives
- September, 2011 (1)
- June, 2011 (2)
- February, 2011 (1)
- January, 2011 (2)
- December, 2010 (1)
- October, 2010 (1)
- September, 2010 (2)
- August, 2010 (3)
- July, 2010 (5)
- May, 2010 (1)
- April, 2010 (1)
- December, 2009 (1)
- November, 2009 (1)
- October, 2009 (2)
- September, 2009 (2)
- August, 2009 (2)
- July, 2009 (1)
- June, 2009 (1)
- May, 2009 (3)
- April, 2009 (4)
- March, 2009 (3)
- February, 2009 (3)
- January, 2009 (3)
- December, 2008 (1)
- November, 2008 (2)
- October, 2008 (4)
- September, 2008 (1)
- August, 2008 (1)
- July, 2008 (3)
- June, 2008 (3)
- May, 2008 (4)
- April, 2008 (1)
- March, 2008 (2)
- February, 2008 (1)
- January, 2008 (3)
- December, 2007 (3)
- September, 2007 (1)
- August, 2007 (1)
- June, 2007 (1)
- May, 2007 (2)
- February, 2007 (1)
- December, 2006 (2)
- November, 2006 (4)
- September, 2006 (1)
- August, 2006 (1)
- May, 2006 (3)
Post Categories
| |
| 29 | 30 | 1 | 2 | 3 | 4 | 5 | | 6 | 7 | 8 | 9 | 10 | 11 | 12 | | 13 | 14 | 15 | 16 | 17 | 18 | 19 | | 20 | 21 | 22 | 23 | 24 | 25 | 26 | | 27 | 28 | 29 | 30 | 31 | 1 | 2 | | 3 | 4 | 5 | 6 | 7 | 8 | 9 |
|