В продолжение прошлого поста про цифры в мире строк.
Почему методы isdigit() и isnumeric() не определяют в строке float и отрицательные значения?
Дело в том, что эти методы работают с ЦИФРАМИ, то есть с единичным символом. А строка "-2" или "3.4" это уже ЧИСЛО. То есть не символ а значение, записанное несколькими символами.
Все озвученные методы проходятся по каждому символу строки и проверяют их индивидуально.
В юникоде есть символы цифр с точками "🄀⒈⒉⒊⒋⒌⒍⒎⒏⒐"
Каждая из них это ОДИН СИМВОЛ, поэтому он будет считаться цифрой
>>> '⒌'.isdigit(), '⒌'.isnumeric()
True, True
Но когда мы пишем это выражение в два символа ( 5+точка), то это не работает.
>>> '5.'.isdigit(), '5.'.isnumeric()
False, False
А еще есть такие символы
>>> '⑴⑵⑶⑷⑸'.isdigit()
True
>>> '🄁🄂🄃'.isdigit()
True
Но они не преобразуются в десятичные цифры
>>> '⒈'.isdecimal()
False
>>> '🄃'.isdecimal()
False
>>> '⑶'.isdecimal()
False
#basic
🚀BIG ANNOUNCEMENT!
🚀
Bitcoin💸 just achieved a monumental milestone, breaking the 💵1 trillion market cap! 🎉📈 With the continuous surge in ATH🔝 (All-Time High) values every day, we can't help but capitalize on this golden opportunity.
📆 SAVE THE DATE: THIS SUNDAY
⌛️Time : 17:00 PM (GMT)
🚀 Pump Target: At least 700%
💰Duration: The pump is expected to last for days.
This isn't just a pump; it's a chance to ride the wave of success in the booming crypto market.
Turn on your notifications and join us on Sunday for an epic pump that could bring massive profits.
Let's make this one for the record books! 💸#BitcoinPump#CryptoSuccess
Got any Questions? @RobertMillercrypto
🔥 Mastercard, Citigroup, and JPMorgan Chase join forces to pilot shared ledger technology for Tokenized Assets settlement processes, with the goal of enhancing speed and security in cross-border transactions. This collaboration could transform the financial sector by enabling diverse asset types to settle on a unified platform.⭐️🌐
#Cryptoassets
#Cryptosuccess
#Blockchainrevolution
🎉SLEX Exchange HITS Top-50 on CoinPaprika! 🚀
💫SLEX Exchange made it into the Top-50 among over 300 cryptocurrency exchanges on CoinPaprika! This achievement highlights our dedication to providing top-notch trading services and robust security.
🤝Thank you to SLEX community for your trust and support. This achievement is as much yours as it is ours!❤️
🔗Check out our ranking: SLEX on CoinPaprika
🦾Come aboard SLEX - wheee crypto and commodity trading meet innovative features. Grow and profit with us! ☄️
#SLEX#Top50#CoinPaprika#CryptoSuccess
Website| Telegram | Reddit | Facebook | Instagram | Medium | Linkedin | Twitter
🚨Crypto Trading Guide for Beginners🚨
Ready to master crypto trading? Join Ekta Mourya from FXStreet as she breaks down how to stop gambling and start building wealth with a structured plan! 💥
Key Insights:
- Stop guessing, understand market cycles 📉
- Avoid 3 common mistakes beginners make ❌
- Use the Crypto Fear & Greed Index to your advantage 🤑
- Top-down analysis with simple tools like RSI & Moving Averages 📊
Start trading like a pro today.
Watch now! 👉https://www.youtube.com/watch?v=R8aAPHvHiKU
#CryptoTradingGuide#BitcoinForBeginners#FXStreet#CryptoSuccess#SmartMoneyConcepts
🚨Crypto Trading Guide for Beginners🚨
Ready to master crypto trading? Join Ekta Mourya from FXStreet as she breaks down how to stop gambling and start building wealth with a structured plan! 💥
Key Insights:
- Stop guessing, understand market cycles 📉
- Avoid 3 common mistakes beginners make ❌
- Use the Crypto Fear & Greed Index to your advantage 🤑
- Top-down analysis with simple tools like RSI & Moving Averages 📊
Start trading like a pro today.
Watch now! 👉https://www.youtube.com/watch?v=R8aAPHvHiKU
#CryptoTradingGuide#BitcoinForBeginners#FXStreet#CryptoSuccess#SmartMoneyConcepts