CN+ has 12 electrons (6 from carbon, 7 for nitrogen, -1 for positive charge). So, we have configuration
(σ1s)2,(σ∗1s)2,(σ2s)2,(σ∗2s)2,(π)4
So, bond order=12(a−b)
a is the number of electrons in bonding molecular orbitals and b is the number of electrons in antibondng molecular orbitals.
Bond Order=12(8−4) =2.