Final version, average accuracy 98%!