It has been shown that 3-formylpyrazolo[1,5-a]pyrazine-4-carboxylates obtained by the selective formylation of pyrazolo[1,5-a]pyrazine-4-carboxylates react with 1,2-ethanediamine or 1,3-propanediamine in methanol at room temperature to give pentaazacyclopenta[d]acenaphthalenes or pentaazaaceanthrylenes.
