Skip to content

Instantly share code, notes, and snippets.

View 536's full-sized avatar
✔️
keep simple

536

✔️
keep simple
View GitHub Profile
@-moz-document domain("zybang.com"),
domain("xin.baidu.com"),
domain("voidcn.com"),
domain("baijiahao.baidu.com") {
html,
body {
background: #FFF;
}
body,
header,
[tpl="recommend_list"],
[class*="-ad-"],
[class*="_ad_"],
[class^="ad_"],
[class^="ad-"],
[class$="_ad"],
[class$="-ad"],
[id$="-ad"],
[id$="_ad"],
[class*="-recommend-"],
@-moz-document url-prefix("chrome-extension://hncgkmhphmncjohllpoleelnibpmccpj") {
html,
body {
overflow: hidden !important;
}
.CodeMirror {
outline: none;
font-family: monospace, sans-serif !important;
}
#help-popup {
@-moz-document domain("github.com") {
html,
body {
min-height: 100vh;
}
body,
img,
video,
.js-header-wrapper,
header.AppHeader {
@-moz-document domain("gist.githubusercontent.com") {
html,
body {
display: flex;
flex-direction: column;
}
html {
background: #111;
}
body {
::-webkit-scrollbar {
background-color: #FAFAFA;
}
::-webkit-scrollbar-thumb {
background-color: #848484;
}
::-webkit-scrollbar-thumb:hover {
background-color: #8f8f8f;
@-moz-document domain("bitbucket.holomatic.ai") {
.filebrowser-readme {
font-family: Source Han Serif;
}
.content-view .CodeMirror pre,
.markup pre code {
font-family: FiraCode Nerd Font;
}
#page {
display: flex;
@536
536 / cmake.sh
Last active May 6, 2024 16:13
install...
#!/bin/bash
set -e
if [ "${1}" == "" ]; then
echo "************************************************************************"
echo "Error: This script needs a parameter: version"
echo " 3.29.2 .etc"
echo "************************************************************************"
exit 1
fi
@536
536 / update-git.sh
Created April 27, 2024 12:22 — forked from YuMS/update-git.sh
Update git to latest version on Ubuntu
#!/bin/bash
sudo add-apt-repository -y ppa:git-core/ppa
sudo apt-get update
sudo apt-get install git -y
@536
536 / 1029.1.py
Last active April 27, 2024 12:09
面试遇到的算法问题
"""
给定一个有序列表l,用最快的方法找出数x在其中的位置
"""
l = [1, 3, 4, 12, 34, 62, 77, 79, 88, 90, 99]
x = 77
"""
思路,先找出数组l的中间值,和x比较大小,若比x大,则x在l的前半部分,
再在l的前半部分的列表ll中,按以上方法判断x的位置
"""