https://docs.python.org/3/library/fractions.html
Код: Выделить всё
import fractions as frc
x = frc.Fraction(5, 7)
Код: Выделить всё
import fractions as frc
x = frc.Fraction(5, 7)
Код: Выделить всё
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Python.File]
@="Python File"
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Python.File\DefaultIcon]
@="\"C:\\Windows\\py.exe\",1"
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Python.File\Shell]
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Python.File\Shell\editwithidle]
"MUIVerb"="&Edit with IDLE"
"Subcommands"=""
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Python.File\Shell\editwithidle\shell]
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Python.File\Shell\editwithidle\shell\edit37]
"MUIVerb"="Edit with IDLE 3.7 (64-bit)"
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Python.File\Shell\editwithidle\shell\edit37\command]
@="\"C:\\Prog\\Python37\\pythonw.exe\" -m idlelib \"%L\" %*"
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Python.File\Shell\open]
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Python.File\Shell\open\command]
@="\"C:\\Windows\\py.exe\" \"%L\" %*"
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Python.File\shellex]
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\Python.File\shellex\DropHandler]
@="{BEA218D2-6950-497B-9434-61683EC065FE}"
Код: Выделить всё
#mouse
from pyautogui import moveTo, click
from time import sleep
while True:
moveTo(1000, 100)
click()
sleep(12)
moveTo(1500, 500)
sleep(13)
Код: Выделить всё
#mouse
import pyautogui as pg
import time
from random import random as rnd
tm = 5*60
rn = tm
pg.FAILSAFE = False
while True:
pg.moveTo(500, 500)
pg.click()
time.sleep(tm + rn * rnd() )
pg.moveTo(600, 300)
pg.click()
time.sleep(tm + rn * rnd() )
Код: Выделить всё
jwt.__file__
Код: Выделить всё
import sys
paths = (
r'C:\code\trunc\game\res\bigworld\scripts\common',
r'C:\code\trunc\game\res\wot\scripts\base',
)
for p in paths:
sys.path.append(p)
Код: Выделить всё
import time
import random
from pynput.keyboard import Controller
keyboard = Controller() # Create the controller
def type_string_with_delay(string):
for character in string: # Loop over each character in the string
keyboard.type(character) # Type the character
delay = random.uniform(0, 2) # Generate a random number between 0 and 10
time.sleep(delay) # Sleep for the amount of seconds generated
type_string_with_delay("This is my string typed with a delay")
Сейчас этот раздел просматривают: 10 гостей