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
| xcode-select --install | |
| sudo cp -R /Applications/WeChat.app /Applications/WeChat2.app | |
| sudo /usr/libexec/PlistBuddy -c "Set :CFBundleIdentifier com.tencent.xinWeChat2" /Applications/WeChat2.app/Contents/Info.plist | |
| sudo codesign --force --deep --sign - /Applications/WeChat2.app | |
| nohup /Applications/WeChat2.app/Contents/MacOS/WeChat >/dev/null 2>&1 & |
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
| #!/bin/bash | |
| # 检查参数 | |
| if [ $# -eq 0 ]; then | |
| echo "Usage: readvideo <video_url_or_audio_file>" | |
| echo "Supports:" | |
| echo " - YouTube: https://www.youtube.com/watch?v=..." | |
| echo " - Bilibili: https://www.bilibili.com/video/BV..." | |
| echo " - Local audio: audio.mp3, audio.m4a, audio.wav, etc." | |
| echo "" |
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
| fio --name=random_read_iops_test \ | |
| --ioengine=posixaio \ | |
| --rw=randread \ | |
| --bs=4k \ | |
| --size=10G \ | |
| --numjobs=16 \ | |
| --iodepth=64 \ | |
| --runtime=60 \ | |
| --time_based \ | |
| --filename=fio_test_file \ |
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
| { | |
| "slot":331916416, | |
| "transaction":{ | |
| "signatures":[ | |
| "3TJB6skkXLyDKxxjREX3tGcMt1DHJxnWoK74KPkoDwNUniXJuhXhKbNrHp4qrqeZofD9gQH7gpX7jfi5RBRxV7uH" | |
| ], | |
| "message":{ | |
| "header":{ | |
| "numRequiredSignatures":1, | |
| "numReadonlySignedAccounts":0, |
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
| #![allow(dead_code)] | |
| use std::fmt::Display; | |
| struct Link<T> { | |
| head: Option<Box<Node<T>>>, | |
| } | |
| struct Node<T> { | |
| value: T, |
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 matplotlib.pyplot as plt | |
| import matplotlib.animation as animation | |
| import numpy as np | |
| class SortingVisualizer: | |
| def __init__(self, array_size=50, speed=10): | |
| """Initialize the sorting visualizer.""" | |
| self.array_size = array_size | |
| self.speed = speed | |
| self.array = np.random.randint(1, 101, array_size) |
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
| #!/usr/bin/env python3 | |
| # -*- coding: utf-8 -*- | |
| import os | |
| import sys | |
| import glob | |
| import sqlite3 | |
| import hashlib | |
| import subprocess | |
| import binascii |
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
| corrupted double-linked list | |
| SIGABRT: abort | |
| PC=0x7f33955b700b m=9 sigcode=18446744073709551610 | |
| signal arrived during cgo execution | |
| goroutine 4363907769 [syscall]: | |
| runtime.cgocall(0x1693870, 0xc221494cb8) | |
| #011runtime/cgocall.go:157 +0x5c fp=0xc221494c90 sp=0xc221494c58 pc=0x41965c | |
| github.com/cockroachdb/pebble/internal/manual._Cfunc_free(0x7f3328b9b2f0) | |
| #011_cgo_gotypes.go:57 +0x45 fp=0xc221494cb8 sp=0xc221494c90 pc=0xaa1145 |
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
| module Mp14 where | |
| import Control.Monad (forM_) | |
| import Control.Monad.ST | |
| import Data.STRef | |
| fibM :: Intger -> Intger | |
| fibM n | |
| | n <= 0 = 0 | |
| | otherwise = runST $ do |
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 Control.Monad (forM_) | |
| import Data.Array | |
| import Data.Array.ST | |
| dynamicProgramming :: Int -> Array Int Int | |
| dynamicProgramming n = runSTArray $ do | |
| arr <- newArray (1, n) 0 | |
| writeArray arr 1 1 | |
| forM_ [2 .. n] $ \i -> do | |
| val <- readArray arr (i - 1) |
NewerOlder