What is %0 ?

%0 is parameter variable that refer to the current running program / batch file. It can be used to have a reference to many related information such as current working directory of the program.

Examples 1 - Display the current working program

echo %0

Examples 2 - Display the working folder of the running program

To display folder of the current working program, we need modifier prefixed with %~[alphabet] (eg : %~d, %~f, etc) followed by 0. 

You can read complete documentation of the modifier here.

echo %~dp0

Result :