"Ну и как же нам перекидывать строки ви числа?" спросите вы. Проверять каждый символ, очистив строку от лишних знаков и точек. Потом конвертить допустимые символы в числа и восстанавливать знак, дробную чусть и тд???
Самый быстрый способ это просто "попробовать" 😜
text = "-0.3"
try:
num = float(text)
except ValueError:
print('Dough!')
Всё остальное это уже парсинг и разбор символов для иных целей.
#basic
CONGO 🇨🇩 L'identité des auteurs de l'attaque ce dimanche matin dans la capitale congolaise révélée. Des images tournées par les assaillants montrent M. Christian #Malanga, membre de la diaspora congolaise résidant aux États-Unis, qui a toujours prôné le retour au #Zaïre, accompagné de son fils et de quelques personnes portant des armes à l’intérieur du Palais de la Nation. Dans une video , les assaillants ont déclarés qu’à partir d’aujourd’hui, "la RDC n'existe plus, c’est le Zaïre".
@egountchibehanzinTV
Three US citizens are accused of being involved in a failed coup attempt in #Congo that left multiple people dead.
According to the Democratic Republic of Congo (#DRC) military, they stopped an attempted #coup near the presidential palace.
Among the 50 people who were involved were three Americans who have been arrested.
A passport for one of these Americans is now spreading online, a 36-year-old U.S. citizen born in Maryland. (WaPo)
#US#Ambassador to Congo, Lucy #Tamlyn has acknowledged the involvement of US citizens in a recent statement.
The coup was allegedly led by US-based Congolese politician Christian #Malanga.
He was killed at the presidential palace after he resisted arrest.