print sqrt(((map/E/g,$s=<>)-map/W/g,$s)**2+((map/N/g,$s)-map/S/g,$s)**2)