CNN dada
04. March 2009
04. March 2009
#!/usr/bin/perl
use LWP::Simple;
system 'clear';
$width = `tput cols`;
$height = `tput lines`;
$text = get('http://rss.cnn.com/rss/edition.rss');
$text =~ s/<[^>]*?>//g;
@words = split(' ', $text);
while(1){
($horiz, $vert) = (int(rand($width)), int(rand($height)));
system 'tput', 'cup', ($vert, $horiz);
print $words[int(rand(scalar @words))];
}