ponctuation : fonction
La présence d’un point d’interrogation (?) indique que le commentaire pourrait être Contre, alors qu’un point d’exclamation (!) serait un indice d’un commentaire Pour.def ponctuation_score(text): num_excl = text.count("!") num_int = text.count("?") return num_excl - num_int