The structure of thalidomide is as follows :-


      
     
     /\     O
    /  \    ||      O
   /    \   /\      \\___
  /  /\  \ /  \     /    NH
 |  /  \  |    \   /      \
 | |    | |     N--        C=O
 |  \  /  |    /   \      /
  \  \/  / \  /     \____/
   \    /   \/
    \  /    ||
     \/     O
     
      
This shows a 6-membered benzene ring fused to a 5 membered nitrogen containing ring, which is then joined to another 6 membered nitrogen containing ring.