Windows: Predefined Environmental Variables
Registry key for system variables:HKEY_LOCAL_MACHINE\ SYSTEM\ CurrentControlSet\ Control\ Session Manager\%SystemDrive% = C:%SystemRoot% = C:\WINDOWS%WinDir% = C:\WINDOWS%SystemDirectory% = C:\WINDOWS\System32%ComSpec% = C:\WINDOWS\system32\cmd.exe%programfiles% = C:\WINDOWS\Program Files%Temp% (or %Tmp%) = C:\Users\<USERNAME>\AppData\Local\Temp or C:\DOCUME~1\<USERNAME>\LOCALS~1\Temp%HOMEDRIVE% =…