Cyanide is one of those pesky polyatomic ions that just must be memorized. Its formula is [tex]CN^{-}[/tex]. The formula for a sodium ion is [tex]Na^{+}[/tex]. These combine in equal proportions to make [tex]NaCN[/tex]. Its high affinity for metals make this really nasty stuff!