Naive Bayes Classifier written in Perl