The reaction between ethanol and semicarbazide is shown below:
\(CH3 − CH = O + H2N − NH − C(= O) − NH2− > CH3 − CH = N − NH − C(= O) − NH2\)
The compound contains three nitrogen atoms
\( \text{M} \xrightarrow{\text{CH}_3\text{MgBr}} \text{N} + \text{CH}_4 \uparrow \xrightarrow{\text{H}^+} \text{CH}_3\text{COCH}_2\text{COCH}_3 \)