The present invention relates to the substituted nitrogenous bicyclic heterocycles of formula (I), and wherein Z is CH2 or N-R4 and X, R1, R2, R4, R6, R7 and n are defined as in the description. The compound is suitable for treating the active obstacle mediated or disease by MDM2 and/or MDM4 or its variant.本發明涉及式(I)的被取代的含氮二環雜環,其中Z是CH2或N-R4且X、R1、R2、R4、R6、R7和n如說明書中所定義。所述化合物適用於治療由MDM2和/或MDM4或其變體的活性所介導的障礙或疾病。