Skip to content

Instantly share code, notes, and snippets.

View yu-hant's full-sized avatar
🎯
Focusing on nothing

Sean Chang yu-hant

🎯
Focusing on nothing
  • Taiwan
View GitHub Profile
@yu-hant
yu-hant / README.md
Created July 26, 2025 08:52
常用 `cmath` 函式

常用 cmath 函式

函式名稱 功能描述 範例
sqrt(x) 開根號,僅適用於 x ≥ 0 sqrt(9.0)3.0
pow(x, y) 計算 x 的 y 次方 pow(2.0, 3.0)8.0
abs(x) 計算整數的絕對值 abs(-5)5
fabs(x) 計算浮點數的絕對值 fabs(-3.2)3.2
ceil(x) 向上取整(天花板函式) ceil(2.3)3.0
floor(x) 向下取整(地板函式) floor(2.9)2.0
@yu-hant
yu-hant / README.md
Created July 4, 2025 07:00
Fix Vmware Workstation Input Lag

Fix Vmware Workstation Input Lag

  1. Right click the VM you want to fix from Library (On your left hand side).
  2. Click Open VM directory
  3. Paste keyboard.vusb.enable = "TRUE" in to *.vmx
@yu-hant
yu-hant / README.md
Created June 16, 2025 22:51
Downgrade from IOS 26 Developer beta

Downgrade from IOS 26 Developer beta

Warning

THIS WILL ERASE YOUR DEVICE. DO NOT DO THIS UNLESS YOU ARE OKAY WITH THAT, OR HAVE A BACKUP.

  1. Download iTunes (exe version).
  2. Download iOS/iPadOS 18.5 from https://ipsw.me.

Note

You can only download signed version (like 18.5)

  1. Open iTunes, and backup your iDevice running 26 Developer beta.

Install Visual Studio Code in Ubuntu

sudo apt update
sudo apt install -y software-properties-common apt-transport-https wget
sudo wget -q https://packages.microsoft.com/keys/microsoft.asc -O /usr/share/keyrings/microsoft.asc
sudo sh -c 'echo "Types: deb\nURIs: https://packages.microsoft.com/repos/vscode/\nSuites: stable\nComponents: main\nSigned-By: /usr/share/keyrings/microsoft.gpg" > /etc/apt/sources.list.d/vscode.sources'
sudo apt update
sudo apt install -y code
@yu-hant
yu-hant / README.md
Last active April 25, 2025 10:01
Easily Restart ZeroTier Service

Easily Restart ZeroTier Service

Warning

You need to run this script with administrator permission, otherwise this script won't work.

Tip

Creating shortcut make your life easier. (Shortcut can set to auto run with administrator permission

C:\Windows\System32\cmd.exe /c C:\Windows\System32\sc.exe stop zerotieroneservice || sc.exe start zerotieroneservice || pause
@yu-hant
yu-hant / README.md
Last active June 6, 2025 12:06
Code Server Help
code-server 4.100.3 409c64e0df4d53530e59c16acc2b5d5766f717b0 with Code 1.100.3                                                                                                                                                                                                                                Usage: code-server [options] [path]                                                                                                                        - Opening a directory: code-server ./path/to/your/project                                                                                              - Opening a saved workspace: code-server ./path/to/your/project.code-workspace                                                                                                                                                                                                                            Options                                                                                                        
@yu-hant
yu-hant / README.md
Created January 31, 2025 03:24
Hypixel Bedwars Command

所有 Hypixel 床戰 的 /play commands

您可以在遊戲中複製貼上 /play 指令,快速進入任何床戰模式的下一個遊戲。

請注意,您無法自行選擇要玩的地圖,地圖是隨機的。

一般床戰指令

單人模式

@yu-hant
yu-hant / README.md
Created January 28, 2025 08:05
Run desktop environment in Google Cloud
docker run -p 8080:80 dorowu/ubuntu-desktop-lxde-vnc --rm
@yu-hant
yu-hant / README.md
Created August 20, 2024 10:22
How To uninstall unwanted preinstalled android app
  1. Make sure you connect to your device
adb devices
  1. print app
adb shell pm list packages 
  1. Uninstall
@yu-hant
yu-hant / README.md
Last active July 14, 2024 08:09
Install Windows via command line

Install Windows via command line

diskpart
    convert gpt
    sel disk 0
    create part efi size=500
    format fs=fat32 quick
    assign letter w
    create part primary
 format quick