python整蛊代码+详解
源代碼
?
import tkinter as tk
import random
import threading
import time
def boom():
? ? window = tk.Tk()
? ? width = window.winfo_screenwidth()
? ? height = window.winfo_screenheight()
? ? a = random.randrange(0, width)
? ? b = random.randrange(0, height)
? ? window.title('你是一個傻狍子')
? ? window.geometry("200x50" + "+" + str(a) + "+" + str(b))
? ? tk.Label(window, text='別惹金澤祺,后果很嚴重!', bg='blue',
? ? ? ? ? ? ?font=('宋體', 17), width=20, height=4).pack()
? ? window.mainloop()
threads = []
for i in range(99999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999):
? ? t = threading.Thread(target=boom)
? ? threads.append(t)
? ? time.sleep(0.1)
? ? threads[i].start()
帶標注
import tkinter as tk
import random
import threading
import time
def boom():
? ? window = tk.Tk()
? ? width = window.winfo_screenwidth()
? ? height = window.winfo_screenheight()
? ? a = random.randrange(0, width)
? ? b = random.randrange(0, height)
? ? window.title('你是一個傻狍子')#標題
? ? window.geometry("200x50" + "+" + str(a) + "+" + str(b))
? ? tk.Label(window, text='別惹金澤祺,后果很嚴重!'#正文內容, bg='blue',#背景顏色
? ? ? ? ? ? ?font=('宋體', 17), width=20, height=4).pack()
? ? window.mainloop()#字體詳細編輯
threads = []
for i in range(99999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999):#彈窗個數
? ? t = threading.Thread(target=boom)
? ? threads.append(t)
? ? time.sleep(0.1)
? ? threads[i].start()
總結
以上是生活随笔為你收集整理的python整蛊代码+详解的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 瘦身长腿、日新小清新治愈系、lomo效果
- 下一篇: waves服务器系统盘,waves服务器