Open notepad, paste below code, save as .bat file.
In SET worlds, include all the worlds that you want to check.
@ECHO off
SET worlds=1,2,3...
FOR %%i IN (%worlds%) DO (
Echo | SET /p=World %%i
FOR /F "tokens=5" %%a IN ('Ping oldschool%%i.runescape.com -n 1 ^| FIND "time="') DO Echo %%a)
PAUSE
Output will be shown like this after you run the bat file.