The N atom and the O+ ion are isoelectronic because each has five valence electrons, or more accurately an electronic configuration of [He] 2s2 2p3.
Similarly, the cations K+, Ca2+, and Sc3+ and the anions Cl−, S2−, and P3− are all isoelectronic with the Ar atom.
CO, CN−, N2, and NO+ are isoelectronic because each has two atoms triple bonded together, and due to the charge have analogous electronic configurations (N− is identical in electronic configuration to O so CO is identical electronically to CN−).
Molecular orbital diagrams best illustrate isoelectronicity in diatomic molecules, showing how atomic orbital mixing in isoelectronic species results in identical orbital combination, and thus also bonding.
More complex molecules can be polyatomic also. For example, the amino acids serine, cysteine, and selenocysteine are all isoelectronic to each other. They differ by which specific chalcogen is present at one location in the side-chain.
CH3COCH3 (acetone) and CH3N2CH3 (azomethane) are not isoelectronic. They do have the same number of electrons but they do not have the same structure.
IUPAC, Compendium of Chemical Terminology, 2nd ed. (the "Gold Book") (1997). Online corrected version: (2006–) "isoelectronic". doi:10.1351/goldbook.I03276 /wiki/International_Union_of_Pure_and_Applied_Chemistry ↩
Isoelectronic Configurations Archived 2017-07-17 at the Wayback Machine iun.edu http://www.iun.edu/~cpanhd/C101webnotes/chemical-bond/isoelectronic.html ↩
A. A. Aradi & T. P. Fehlner, "Isoelectronic Organometallic Molecules", in F. G. A. Stone & Robert West (eds.) Advances in Organometallic Chemistry Vol. 30 (1990), Chapter 5 (at p. 190) google books link https://books.google.com/books?id=e6R4oMRDhvsC&pg=PA190 ↩