Skip to content

Instantly share code, notes, and snippets.

View QGB's full-sized avatar
💭
unhappy=

Too large to fit in the margin QGB

💭
unhappy=
  • Please
  • Follow me
View GitHub Profile
@QGB
QGB / F.py
Last active March 22, 2023 11:51
QPSU
def hexToBytes(a,split='',ignore_space=True):
T=py.importU().T
if ignore_space and ' ' not in split:a=T.removeAllSpace(a)
it=2
if len(split)>0:it+=len(split)
if it==2 and len(a) % it!=0:return ()
a=a.upper();r=b''
@QGB
QGB / YouTube
Created November 3, 2021 08:37
$("video.html5-main-video").ontimeupdate=function(){
console.log(arguments,document.querySelector("video.html5-main-video").currentTime)
}
ƒ (){
console.log(arguments,document.querySelector("video.html5-main-video").currentTime)
}
VM5557:2 Arguments [Event, callee: ƒ, Symbol(Symbol.iterator): ƒ] 290.331737
VM5557:2 Arguments [Event, callee: ƒ, Symbol(Symbol.iterator): ƒ] 290.427104
VM5557:2 Arguments [Event, callee: ƒ, Symbol(Symbol.iterator): ƒ] 290.632047
VM5557:2 Arguments [Event, callee: ƒ, Symbol(Symbol.iterator): ƒ] 290.800068
Description
The sub() method embeds a string in a <sub> tag: "<sub>str</sub>".
Examples
Using sub() and sup() methods
The following example uses the sub() and sup() methods to format a string:
@QGB
QGB / gist:7ff7b21efec89b338a460ab208a716d5
Created August 18, 2021 07:25
leetcode print-zero-even-odd
import threading
cz= threading.Condition()
cq= threading.Condition()
ce= threading.Condition()
class ZeroEvenOdd:
def __init__(self, n):
self.n = n
self.q=1
self.e=2
@QGB
QGB / QShell.sh
Created December 19, 2018 02:55
shell@HS8917QC:/ $ [ "$pyPath" != "" ] || echo 233
233
shell@HS8917QC:/ $
shell@HS8917QC:/ $ env|grep qs
qscript=//qshell
qsPath=//
shell@HS8917QC:/ $ unset qsPath
shell@HS8917QC:/ $ [ "$pyPath" != "" ] || echo 233 #不能检测 环境变量
233
shell@HS8917QC:/ $ env|grep qs
@QGB
QGB / git.py
Created January 30, 2020 08:38
import sys;'qgb.U' in sys.modules or sys.path.append('C:/qgb/');from qgb import *
import dulwich
import dulwich.client
from dulwich.repo import Repo
from dulwich import index
import os
import shutil
def clone(url,path=None):
{
"git.ignoreLegacyWarning": true,
"terminal.integrated.shell.windows": "C:\\Windows\\System32\\cmd.exe",
"window.zoomLevel": 1,
"editor.accessibilitySupport": "off",
"diffEditor.ignoreTrimWhitespace": true,
"files.autoSave": "afterDelay",
"rust.rustup": {
"toolchain": "nightly-x86_64-unknown-linux-gnu",
"nightlyToolchain": "nightly-x86_64-unknown-linux-gnu"
@QGB
QGB / asyncio_loops.py
Created November 20, 2019 12:12 — forked from lars-tiede/asyncio_loops.py
asyncio + multithreading: one asyncio event loop per thread
import asyncio
import threading
import random
def thr(i):
# we need to create a new loop for the thread, and set it as the 'default'
# loop that will be returned by calls to asyncio.get_event_loop() from this
# thread.
loop = asyncio.new_event_loop()
http://192.168.1.111:23571/response.headers['Content-Type']='text/html';
response.headers['X-XSS-Protection']=0;
r='''
<form method="post" action="http://192.168.1.111:23571/r=request.get_data">
<input type="text" name="t">
<input type="file" name="f">
<input type="submit" />
</form>
YandexBrowser browser://activation/ 不能乱点,这会 导致浏览器重新初始化,所有未同步的修改全部丢失!!所有设置重置
但是如果遇到无法登录同步的情况,重新初始化却能登录
登录同步之后,首先同步密码,只要几秒钟,
书签大约10分钟同步完成
同步扩展