The demonstration came as the United States, South Korea and Japan held combined military exercises in nearby waters.