modified logic of extracting population names.