fa
Feedback
Cᴏᴅᴇs Sɴɪᴘᴘᴇᴛs

Cᴏᴅᴇs Sɴɪᴘᴘᴇᴛs

رفتن به کانال در Telegram

👩‍💻 Wᴇʟᴄᴏᴍᴇ ᴛᴏ @CodesSnippet! 🚀 Jᴏɪɴ ᴜs ғᴏʀ ᴅᴀɪʟʏ sɴɪᴘᴘᴇᴛs ᴏғ ᴄᴏᴅɪɴɢ 🧩 ᴋɴᴏᴡʟᴇᴅɢᴇ! 💻💡 Hᴇʀᴇ, ʏᴏᴜ'ʟʟ ғɪɴᴅ 👀 ʙɪᴛᴇ-sɪᴢᴇᴅ ᴘɪᴇᴄᴇs ᴏғ ᴄᴏᴅᴇ, 🔥 ᴘʀᴏɢʀᴀᴍᴍɪɴɢ ᴛɪᴘs, ᴀɴᴅ ᴛʀɪᴄᴋs ᴛᴏ ʟᴇᴠᴇʟ ᴜᴘ ʏᴏᴜʀ ᴄᴏᴅɪɴɢ sᴋɪʟʟs! 💪💻 Sᴛᴀʏ ᴜᴘᴅᴀᴛᴇᴅ ᴏɴ ᴛʜᴇ ʟᴀᴛᴇsᴛ ᴛʀᴇɴᴅs ɪɴ ᴛᴇᴄʜ

نمایش بیشتر
کشور مشخص نشده استفناوری و برنامه‌ها51 481
305
مشترکین
اطلاعاتی وجود ندارد24 ساعت
-67 روز
-630 روز
آرشیو پست ها
⌨️ 📺 Downloading a YouTube Playlist using Python
⌨️ 📺 Downloading a YouTube Playlist using Python

Find system name , version processor using python.
import platform

system_name = platform.system()

system_version = platform.version()

architecture = platform.architecture()[0]

processor = platform.processor()

print("OS:", system_name)
print("OS Version:", system_version)
print("32 or 64:", architecture)
print("Processor :", processor)
Jᴏɪɴ ᴜs :- @Python_Codes_Pro Support group :- @python_group_pro

Run Javascript code using python subprocess Library
import subprocess
js_code = """
console.log("Hello, World!");
"""

with open("script.js", "w") as file:
    file.write(js_code)

result = subprocess.run(["node", "script.js"], capture_output=True, text=True)

print(result.stdout)
By : @Mr_Sukkun

Which of the following is not one of the quotation marks we use when writing code in Python?
Anonymous voting

Don't give up, stay focused 🤝 #programming #code #dailypost #motivation #coder

⌨️ Remove the Background of an Image Using Python # pip install rembg pillow from rembg import remove from PIL import Image i
⌨️ Remove the Background of an Image Using Python
# pip install rembg pillow

from rembg import remove
from PIL import Image

input_path = "in.png"
output_path = "out.png"

input = Image.open(input_path)
output = remove(input)
output.save(output_path)
📱 Join us for more Python tips: @CodesSnippet #python #programming #code #python3 #dailypost

Repost from PYTHON PROGRAMMING
print(7>6.1>6>5>=5.0)
Anonymous voting

y=lambda x: x*True print(5)
Anonymous voting

y=lambda x: x*False print(y(5))
Anonymous voting

print(len(34))
Anonymous voting

Python notes
+9
Python notes

Task: You have to create a program where a list of numbers is given and a number of rotation is given. Now you to bring last number of list in front and swift each number to the right. Do this till the given number of rotation. Sample :- input - [1,2,3,4] , 2 output - [4,1,2,3] -> [3,4,1,2] Good luck!

X=['h', 'i'] Y=['i','h'] print(X==Y)
Anonymous voting

X=['h', 'i'] Y=sorted(['i','h']) print(X==Y)
Anonymous voting

Check either string is an Anagram or not?
def is_anagram(str1,str2):

    return sorted(str1)==sorted(str2)

#print(is_anagram("astronomer","moonstarer"))
#Output : True

Guess the Output???
def foo(a,b=10,c=7):

    return a+b+c

print(foo(a=1,b=8))

# Convert Timestamp to Indian Time Zone Using Python. 

import datetime
import pytz

def convert_timestamp_to_ist(timestamp: int) -> str:
    utc_date_time = datetime.datetime.utcfromtimestamp(timestamp)
    
    utc_time_zone = pytz.timezone('UTC')
    utc_aware_datetime = utc_time_zone.localize(utc_date_time)
    
    ist_time_zone = pytz.timezone('Asia/Kolkata')
    ist_aware_datetime = utc_aware_datetime.astimezone(ist_time_zone)
    
    formatted_date = ist_aware_datetime.strftime('%A, %Y-%m-%d %H:%M:%S')
    
    return formatted_date

# print(convert_timestamp_to_ist(1717000920))
Output:
  Wednesday, 2024-05-29 22:12:00

Choose the correct answer
Anonymous voting

...
...