@NEASingapore · Post #855 · 07.07.2024 г., 01:02
🚩 Red flag alert 🚩 Say “No” to single-use plastics! Embrace reusable alternatives instead. Every action counts towards a greener future! #SayYEStoWasteLess
Hashtags
TGINSIGHT SIMILAR POSTS
Изворен канал @pythonotes · Post #76 · 27 апр.
Ранее я делал серию постов про битовые операторы. Вот вам ещё один наглядный пример как это используется в Python в модуле re. Чтобы указать флаг для компилятора нам надо указать его после передаваемой строки. Например, добавляем флаг для игнорирования переноса строки. pattern = re.compile(r"(\w+)+") words = pattern.search(text, re.DOTALL) А как указать несколько флагов? Ведь явно будут ситуации когда нам потребуется больше одного. Кто читал посты по битовые операторы уже понял как. pattern.search(text, re.DOTALL | re.VERBOSE) А теперь смотрим исходники, что находится в этих атрибутах? Не удивительно, степени двойки. Почему? Потому что каждое следующее значение это сдвиг единицы влево. >>> for n in [1, 2, 4, 8, 16, 32, 64, 128, 256]: >>> print(bin(n)) 0b1 0b10 0b100 0b1000 0b10000 0b100000 0b1000000 0b10000000 0b100000000 Чтобы было понятней, давайте напишем тоже самое но иначе, добавим ведущие нули: 000000001 000000010 000000100 000001000 000010000 000100000 001000000 010000000 100000000 Не понятно что тут происходит? Читай три поста про битовые операторы начиная с этого ➡️https://t.me/pythonotes/45 В общем, это пример применения побитовых операций в самом Python. Теперь вы знаете Python еще немного лучше) #tricks#regex#libs
Пребарај: #sayyestowasteless
@NEASingapore · Post #855 · 07.07.2024 г., 01:02
🚩 Red flag alert 🚩 Say “No” to single-use plastics! Embrace reusable alternatives instead. Every action counts towards a greener future! #SayYEStoWasteLess
Hashtags
@NEASingapore · Post #717 · 10.12.2023 г., 01:02
Looking forward to festive feasting? Here’s how you can feast ✨smart✨: Order only what you can finish and enjoy the satisfaction of a clean plate and choices well-made 🍴 #SayYesToWasteLess
Hashtags
@NEASingapore · Post #312 · 30.01.2022 г., 02:30
Order or cook just enough for you and your guests, to avoid wasting food this Lunar New Year. Let’s also observe safe management measures, to keep ourselves and our loved ones safe. #SayYEStoWasteLess
Hashtags
@NEASingapore · Post #35 · 08.04.2020 г., 03:40
#SayYesToWasteLess by bringing your own clean containers when tabao-ing! https://youtu.be/yIdHQ5LB0JE
Hashtags
@NEASingapore · Post #1169 · 15.11.2025 г., 01:03
🎶 Ooooo~ This is an S.O.S.! 🎶 Good deals may be tempting but just because it’s on discount doesn’t mean you have to buy it. Reduce food wastage during the upcoming year-end festivities: ✅ Plan your meals and prep a shopping list ✅ Order only what you can finish ✅ Transform leftovers into new dishes #SayYEStoWasteLess#SustainableSG
Hashtags
@NEASingapore · Post #1207 · 25.12.2025 г., 00:54
By reducing waste and recycling right, we help protect our environment and extend landfill capacity. Let’s safeguard, nurture, and cherish our environment for future generations. 🌱 #SayYESToWasteLess#TowardsZeroWaste
@NEASingapore · Post #723 · 16.12.2023 г., 01:00
As the festive clock ticks, let's not forget the ticking dates in our pantry! Place items nearing their expiry dates at the front of your shelves. This helps you remember to use them soon and reduce food wastage. #SayYEStoWasteLess#TowardsZeroWaste
@NEASingapore · Post #722 · 15.12.2023 г., 01:02
This holiday season, let's embrace moderation over mountains of food! Avoid waste! Choose portions that are just right and delight in every bite. 😋 #SayYEStoWasteLess#TowardsZeroWaste
@NEASingapore · Post #501 · 04.02.2023 г., 02:01
Have leftover items from your Lunar New Year festivities? Be sure to place food that is near expiry within view, and practise the “First to Expire, First Out” approach when organising your home pantry! #SayYEStoWasteLess#TowardsZeroWaste
@NEASingapore · Post #499 · 28.01.2023 г., 02:01
A scrumptious meal with your family and friends doesn’t have to be excessive. If they are visiting other places beforehand, check with them first on how much they can eat. Let’s cook or order only what we can finish, to avoid food waste! #TowardsZeroWaste#SayYEStoWasteLess
@NEASingapore · Post #496 · 24.01.2023 г., 01:30
If you have extra steamboat ingredients from Lunar New Year gatherings, store these leftovers properly to keep them fresh for a longer time and avoid food wastage! More tips at www.nea.gov.sg/food-waste-management-strategies #TowardsZeroWaste#SayYEStoWasteLess
@NEASingapore · Post #447 · 22.10.2022 г., 01:30
Collecting more candy than we can finish this Halloween is less of a treat and more like a trick that leads to food waste! Say no to excessive candy, just like how you should only order and cook what you can eat. #SayYEStoWasteLess#TowardsZeroWaste