#!/usr/bin/perl
open(TL,">test.txt");
print TL ("error");
close (TL);
$error = grep(/error/,test.txt);
printf ("ERROR %d ",$error);