How to determine whether a given compound is paramagnetic or diamagnetic?
Paramagnetism is a consequence of having one or more un-paired electrons in the outer electronic configuration. e.g. O$_2$, and NO. An an odd number of electrons can clearly produce a paramagnetic ion, radical or molecule. However, molecules with an even number of electrons can also be paramagnetic, the most famous being dioxygen (O$_2$). The experimental observation is that oxygen is attracted to a magnet.(This is best observed with liquid oxygen.) Nitrogen (N$_2$) is not paramagnetic but diamagnetic.  Whether a molecule is paramagnetic or not is only explained using molecular orbital theory. In the case of O$_2$ it is found that the lowest energy state is one that has one electron in each of two orbitals. An alternative would be to expend energy to pair up these two electrons into one orbital. As this requires energy it does not occur. High and low spin transition metal complexes show the same effect of pairing vs. placing electrons into different orbitals.