Ping script using Python