A subwavelength atomic array switched by a single Rydberg atom