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

TGINSIGHT SIMILAR POSTS

Најди сличен содржај

Изворен канал @pythonotes · Post #281 · 18 авг.

Что-то вы гоните насчет "привычного вида формата 755 и 644". Я вот вообще не понял что это!😳 Действительно, что означают цифры которые мы получили в прошлом посте? Это кодировка, заключающая в себе режимы доступа к файлу. Подробней можно почитать в статье про chmod. Там можно увидеть альтернативное обозначение того же самого с помощью символов r w x, что значит чтение, запись, исполнение. Чтобы преобразовать восьмеричное число в такое обозначение в Python есть готовая функция >>> stat.filemode(0o755) '?rwxr-xr-x' Мы видим 3 группы по 3 символа, дающие 3 типа доступа для 3 типов юзеров. А что за знак вопроса в начале? Давайте передадим в эту функцию необрезанное значение от os.stat >>> stat.filemode(os.stat(path).st_mode) 'drwxr-xr-x' Это данные, которые мы безжалостно обрезали в прошлый раз😼 Первый символ обозначает тип объекта. Это может быть файл (-), директория (d) или симлинк (l). Вот простая схема данной кодировки [1][3][3][3] │ │ │ │ │ │ │ └──> Others Permissions │ │ └─────> Group Permissions │ └────────> Owner Permissions └───────────> File Type (разверните экран если вы с телефона) Если вы попробуете получить пермишены для симлинка то получите пермишены для файла >>> path = '.venv/bin/python3' >>> stat.filemode(os.stat(path).st_mode) '-rwxr-xr-x' Чтобы получить свойства именно симлинка, нужно это явно указать >>> stat.filemode(os.stat(path, follow_symlinks=False).st_mode) 'lrwxrwxrwx' #tricks#basic

Резултати

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

Пребарај: #russianclasses

当前筛选 #russianclasses清除筛选
Russian House Brussels-Europe

@rushousebrussels · Post #2116 · 02.10.2024 г., 06:32

Today we continue the topic of confusing emphases! You can find the previous post here. ❓And, as per our tradition, I have a question: What word pairs confused you the most when speaking Russian? Share your stories in the comments! 📸: Pavel Kuzmichev, OZ_Media, Lucy Lambriex, LauriPatterson, bymuratdeniz, David Wall, Westend61, Mariha-kitchen, stocknshares/Getty Images #russianclasses 🔔Russia Beyond

Russian House Brussels-Europe

@rushousebrussels · Post #2103 · 18.09.2024 г., 09:11

Let's learn the diminutive forms for animal names! тигр -> тигрёнок медведь -> медвежонок слон -> слонёнок курица -> цыплёнок лошадь -> жеребёнок ❓Would you like to have any of these as a pet? :) P.S. Catch more of my lessons on YouTube! #russianclasses

Russian House Brussels-Europe

@rushousebrussels · Post #2100 · 10.09.2024 г., 07:54

Привет! We already made blini and kvass - time for okroshka! You’ll find the exact amounts of the ingredients to use here. ❓Have you tried okroshka? And what would you like to cook for next time? 📷: Maria Afonina; Yulia Gusterina/Getty Images #russianclasses 🔔Russia Beyond

Привет, салют и здравствуйте! Today we'll learn 5 Russian greetings. Formal ones: 🇷🇺Здравствуйте! 🇬🇧Hello! 🇷🇺Приветствую! 🇬🇧Greetings! Informal: 🇷🇺Привет! 🇬🇧Hi! 🇷🇺Салют! 🇬🇧Salutations! (Literally: "firework!") Very informal and conversational: 🇷🇺Здорово! (pronounced as ‘здарова!’) 🇬🇧Hey/What's up! ❓Do you know other (unusual) Russian greetings? Drop them in the comments! P.s. watch more videos here! #russianclasses 🔔Russia Beyond

Russian House Brussels-Europe

@rushousebrussels · Post #2085 · 27.08.2024 г., 13:19

🔊Sound on ☕ please, repeat Привет! Tired of learning Russian? Great news for you today then: we have thousands of words that are similar to English ones! Let’s start with those relating to food! Notice that the pronunciation is not always similar, so watch out for those accents! Still, learning Russian versions of the words you already know is far easier than learning absolutely new ones 🙂 That’s not the end of the list! Do you have any more examples? Drop them down in the comments! 👇🏼 Credits: Westend61, Aleksandr Kuzmin, Martin Barraud, serggn, Chris Stein, Halfdark/Getty Images Sourse: Russia Beyond https://t.me/russiabeyond/8927 #russianclasses#russianbeyond#РусскийДом#RussianHouse#Образование#КРЯ#brussels#belgium#educationrussia#RussianHouseBrussels#russianlanguagecoursesbrussels#russianlanguage#learnrussian#studyrussian