#!/usr/bin/perl -w

use strict;

print "Content-Type: text/html; charset=ISO-8859-1\n\n";

open(F, "/home/gk/www/b0rk.org/theo/theo.c") || die $!;
my @quotes;
my $start = 0;

while(defined($_ = <F>))
{
	if (m/^static const char \*talk.*/)
	{
		$start = 1;
		next;
	}
	last if (m/^\};/ && $start);
	chomp;
	s/^\s*"//g; s/"\s*,*$//g;
	push @quotes, $_ if ($start);
}
close(F);

my $quote = $quotes[rand(scalar @quotes)];

print '<html><head><style>
	h4 {text-align:center;}
	p {text-align:center;}
	</style>
	</head>
	<body>';

print "<h4><br><br><br>$quote</h4></body></html>\n";


