Electrolysis of benzylthiocyanate, benzyl chloride, p-methylbenzyl chloride, p-methoxybenzyl chloride, or toluene in acetonitrile, at platinum electrodes in a two compartments cell divided by a glass-frit diaphragm, affords 2,6-dimethyl-4-arylpyridine-3,5-dicarbonitrile as major product.