Hard x-ray photoemission spectroscopy (PES) of Cu core electronic states, with a probing depth of approximately 60 A, is used to show that the Zhang-Rice singlet feature is present in La2CuO4 but is absent in Nd2CuO4. Hole and electron doping in La(2-x)SrxCuO4 (LSCO) and Nd(2-x)CexCuO4 (NCCO) result in new well-screened features which are missing in soft x-ray PES. Impurity Anderson model calculations establish screening from doped states as its origin, which is strongly suppressed within 15 A of the surface. Complemented with x-ray absorption spectroscopy, the small chemical-potential shift in core levels (approximately 0.2 eV) are shown to be consistent with modifications of valence and conduction band states spanning the band gap (approximately 1 eV) upon hole and electron doping in LSCO and NCCO.