a simple classifier and testing program