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

Резултати

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

Пребарај: #wayland

当前筛选 #wayland清除筛选
Linuxgram 🐧

@linuxgram · Post #18596 · 28.04.2026 г., 10:02

📰WayVNC 0.10 Released For Advancing This Leading VNC Server For Wayland WayVNC 0.10 is out today as the newest feature release for this VNC server that works with Wayland compositors leveraging the wlroots library... 🔗 Source: https://www.phoronix.com/news/WayVNC-0.10-Released #wayland

Hashtags

Linuxgram 🐧

@linuxgram · Post #18569 · 25.04.2026 г., 19:03

📰 Niri 26.04 Brings Long-Awaited Blur Support to the Wayland Compositor Niri 26.04 scrollable-tiling Wayland compositor adds long-awaited blur support, improved screencasting, faster rendering, and more. 🔗 Source: https://linuxiac.com/niri-26-04-brings-long-awaited-blur-support-to-the-wayland-compositor/ #wayland

Hashtags

Linuxgram 🐧

@linuxgram · Post #18464 · 16.04.2026 г., 19:14

📰 Mir 2.26 Begins Working On Rust-Based Input Platform Canonical today released Mir 2.26 as the newest feature release for this compositor for building Wayland-based shells. Notable with Mir 2.26 is a Rust-based input platform is in development as part of their broader effort for bringing Rust code into Mir... 🔗 Source: https://www.phoronix.com/news/Mir-2.26-Released #wayland

Hashtags

Linuxgram 🐧

@linuxgram · Post #18396 · 11.04.2026 г., 19:06

📰 Cage 0.3 Released With New Wayland Protocol Support Cage as the Wayland compositor providing a kiosk mode for single, maximized apps is out with a new feature release more than six months after its prior version... 🔗 Source: https://www.phoronix.com/news/Cage-0.3-Released #wayland

Hashtags

Linuxgram 🐧

@linuxgram · Post #18362 · 09.04.2026 г., 08:08

📰Miracle-WM 0.9 Makes This Mir-Based Wayland Compositor Truly Hackable Miracle-WM 0.9 brings WebAssembly plugins, a new Rust API, cursor theme support, and faster performance for this Mir-based Wayland compositor. 🔗 Source: https://linuxiac.com/miracle-wm-0-9-makes-this-mir-based-wayland-compositor-truly-hackable/ #wayland

Hashtags

Linuxgram 🐧

@linuxgram · Post #18353 · 08.04.2026 г., 16:37

📰 16 contributors, cross-stack improvements: Collabora's work on GStreamer 1.28 Our multimedia engineering team delivered major improvements to GStreamer 1.28: hardware acceleration and zero-copy pipelines, HDR and color support for Wayland, AI inference integration, plus critical codec and RTP/WebRTC interoperability fixes. 🔗 Source: https://www.collabora.com/news-and-blog/news-and-events/16-contributors-cross-stack-improvements-collabora-work-gstreamer-128.html #wayland

Hashtags

Linuxgram 🐧

@linuxgram · Post #18335 · 07.04.2026 г., 15:15

📰 Alacritty 0.17 Terminal Emulator Released with Wayland Resize Improvements Alacritty 0.17, a GPU-accelerated terminal emulator, adds TOML 1.1 support, Wayland resize increments, mouse wheel bindings, and more. 🔗 Source: https://linuxiac.com/alacritty-0-17-terminal-emulator-released-with-wayland-resize-improvements/ #wayland

Hashtags

Linuxgram 🐧

@linuxgram · Post #18270 · 01.04.2026 г., 13:26

📰 Wayland Protocols 1.48 Released With XDG Session Management Wayland Protocols 1.48 is out today with the long-awaited XDG Session Management protocol in tow as well as several new experimental protocols... 🔗 Source: https://www.phoronix.com/news/Wayland-Protocols-1.48 #wayland

Hashtags

Linuxgram 🐧

@linuxgram · Post #18215 · 27.03.2026 г., 19:15

📰Hyprland 0.54.3 Wayland Compositor Released With Crash Fixes Hyprland 0.54.3 delivers fixes for crashes in compositor, layout handling, and XWayland, improving overall stability in this patch release. 🔗 Source: https://linuxiac.com/hyprland-0-54-3-wayland-compositor-released-with-crash-fixes/ #wayland

Hashtags

Linuxgram 🐧

@linuxgram · Post #18116 · 19.03.2026 г., 16:46

📰 Wayland 1.25 Released With Color Management Now Fully Documented Article from Phoronix. Read more at the original link. 🔗 Source: https://www.phoronix.com/news/Wayland-1.25-Released #wayland

Hashtags

Linuxgram 🐧

@linuxgram · Post #18074 · 16.03.2026 г., 12:53

📰 River 0.4 Wayland Compositor Debuts Pluggable Window Managers River 0.4 introduces a new architecture separating the Wayland compositor from the window manager. 🔗 Source: https://linuxiac.com/river-0-4-wayland-compositor-debuts-pluggable-window-managers/ #wayland

Hashtags

Linuxgram 🐧

@linuxgram · Post #17990 · 06.03.2026 г., 09:26

📰 Wayland 1.25 RC1 Released With Improved Documentation, Minor Changes Simon Ser announced the release today of Wayland 1.25 RC1 (Wayland v1.24.91) in working toward this next stable release... 🔗 Source: https://www.phoronix.com/news/Wayland-1.25-RC1 #wayland

Hashtags

ПретходнаСтраница 1 од 4Следна