Transition metal-free one-pot synthesis of nitrogen-containing heterocycles