TGTGInsighttelegram intelligenceLIVE / telegram public index
← Python Заметки

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

Резултати

Пронајдени 85 слични објави

Пребарај: #sgdengueupdate

当前筛选 #sgdengueupdate清除筛选
NEA Singapore

@NEASingapore · Post #701 · 10.11.2023 г., 03:48

#SGDengueUpdate 153 new dengue cases and 53 active dengue clusters were reported in the week ending 4 Nov 2023. If you are living in a dengue cluster area, or have been diagnosed with or are suspected to be infected with dengue,carry out ‘S-A-W’ and ‘B-L-O-C-K’ actions immediately: https://go.gov.sg/mozzieproof ⚠️ Continued urgent action from all is critical to prevent a surge in dengue cases at year-end.

NEA Singapore

@NEASingapore · Post #697 · 02.11.2023 г., 09:37

#SGDengueUpdate 191 new dengue cases and 50 active dengue clusters were reported in the week ending 28 Oct 2023. If you are living in a dengue cluster area, or have been diagnosed with or are suspected to be infected with dengue,carry out ‘S-A-W’ and ‘B-L-O-C-K’ actions immediately: https://go.gov.sg/mozzieproof ⚠️ Continued urgent action from all is critical to prevent a surge in dengue cases at year-end.

NEA Singapore

@NEASingapore · Post #682 · 20.10.2023 г., 00:39

#SGDengueUpdate 215 new dengue cases and 66 active dengue clusters were reported in the week ending 14 Oct 2023. If you are living in a dengue cluster area, or have been diagnosed with or are suspected to be infected with dengue,carry out ‘S-A-W’ and ‘B-L-O-C-K’ actions immediately: https://go.gov.sg/mozzieproof The weekly number of dengue cases has increased steadily, and is expected to rise beyond the traditional peak dengue season, with many dengue clusters across the island. Urgent action from all is critical to prevent a surge in dengue cases at year-end.

NEA Singapore

@NEASingapore · Post #667 · 12.10.2023 г., 09:28

#SGDengueUpdate 267 new dengue cases and 90 active dengue clusters were reported in the week ending 7 Oct 2023. If you are living in a dengue cluster area, or have been diagnosed with or suspected to be infected with dengue,carry out ‘S-A-W’ and ‘B-L-O-C-K’ actions immediately: https://go.gov.sg/mozzieproof ⚠️ The number of dengue cases is expected to rise beyond the traditional peak dengue season, as fast rate of dengue transmission is seen in dengue clusters across the island. Urgent action from all is critical to prevent a surge in dengue cases at year-end.

NEA Singapore

@NEASingapore · Post #655 · 05.10.2023 г., 10:15

#SGDengueUpdate 343 new dengue cases and 76 active dengue clusters were reported in the week ending 30 Sep 2023. No new Zika cases were reported last week. If you are living in a dengue cluster area, or have been diagnosed with or suspected to be infected with dengue,carry out ‘S-A-W’ and ‘B-L-O-C-K’ actions immediately: https://go.gov.sg/mozzieproof

NEA Singapore

@NEASingapore · Post #649 · 28.09.2023 г., 09:14

#SGDengueUpdate 303 new dengue cases and 64 active dengue clusters were reported in the week ending 23 Sep 2023. No new Zika cases were reported last week. If you are living in a dengue cluster area, or have been diagnosed with or suspected to be infected with dengue,carry out ‘S-A-W’ and ‘B-L-O-C-K’ actions immediately: https://go.gov.sg/mozzieproof

NEA Singapore

@NEASingapore · Post #647 · 21.09.2023 г., 09:53

#SGDengueUpdate 330 new dengue cases and 56 active dengue clusters were reported in the week ending 16 Sep 2023. Two new Zika cases were also reported last week. The number of dengue cases at Toa Payoh remains high. If you are living in a dengue cluster area, or have been diagnosed with or suspected to be infected with dengue,carry out ‘S-A-W’ and ‘B-L-O-C-K’ actions immediately: https://go.gov.sg/mozzieproof

NEA Singapore

@NEASingapore · Post #643 · 14.09.2023 г., 09:10

#SGDengueUpdate 261 new dengue cases and 53 active dengue clusters were reported in the week ending 9 Sep 2023. There are two fast-growing dengue clusters at Science Park Drive (47 cases) and Lentor Loop (33 cases). The number of dengue cases at Toa Payoh remains high. If you are living in a dengue cluster area, or have been diagnosed with or suspected to be infected with dengue,carry out ‘S-A-W’ and ‘B-L-O-C-K’ actions immediately: https://go.gov.sg/mozzieproof

NEA Singapore

@NEASingapore · Post #640 · 07.09.2023 г., 10:06

#SGDengueUpdate 213 new dengue cases and 42 active dengue clusters were reported in the week ending 2 Sep 2023. There are two fast-growing dengue clusters at Science Park Drive (26 cases) and Lentor Loop (22 cases). The number of dengue cases at Toa Payoh remains high. Particularly if you are living in a dengue cluster area, or have been diagnosed with or suspected to be infected with dengue,carry out ‘S-A-W’ and ‘B-L-O-C-K’ actions immediately: https://go.gov.sg/mozzieproof

NEA Singapore

@NEASingapore · Post #276 · 26.10.2021 г., 10:16

#SGDengueUpdate Over 4,500 dengue cases have been reported this year, and there are currently 12 active dengue clusters. Although recent weekly dengue cases have been lower than during the same period in 2020, we should all continue to stay vigilant, to prevent a year-end rise in dengue cases amid higher circulation of less common Dengue virus serotype 3 (DENV-3)! Learn how you can prevent Aedes mosquitoes from breeding in your home: www.nea.gov.sg/dengue-zika/prevent-aedes-mosquito-breedin

NEA Singapore

@NEASingapore · Post #155 · 26.01.2021 г., 10:35

#SGDengueUpdate The number of weekly dengue cases has come down slightly to 156 cases as of 23 Jan. However, the Aedes aegypti mosquito is still high in parts of Singapore. Coupled with a sizeable proportion of people still working from home, the risk of dengue remains high in 2021. The strong support from our stakeholders and the public helped to bring down the weekly number of dengue cases from its peak of 1,792 in Jul 2020. Let’s stay vigilant in this fight against dengue! Here’s how: www.nea.gov.sg/stop-dengue

NEA Singapore

@NEASingapore · Post #137 · 03.12.2020 г., 03:41

#SGDengueUpdate 281 weekly dengue cases were reported last week, reversing the downward trend in the number of weekly dengue cases over the past 6 weeks. The Aedes mosquito population has also increased by 11% since the second week of Nov. Let’s all stay vigilant and do our part to reduce the Aedes mosquito population! Learn more: go.gov.sg/mozzieproof

123•••78
ПретходнаСтраница 1 од 8Следна