The present invention relates to a compound of formulawhereinHetAr is a five or six membered hetaryl group, containing one, two or three heteroatoms, selected from N, O or S;R1 is hydrogen, lower alkyl, lower alkyl substituted by halogen, halogen, or lower alkoxy;R2 is lower alkyl substituted by halogen, —;CH2—;C3-6-cycloalkyl, substituted by one or two substituents, selected from lower alkyl substituted by halogen or halogen, or is lower alkenyl substituted by halogen;R3 is hydrogen, lower alkyl substituted by halogen, lower alkyl, halogen, C3-6-cycloalkyl or lower alkyl substituted by hydroxy;n is 1 or 2; for n=2, R1 can be independent to each other;Y is CH or N;or to a pharmaceutically active acid addition salt thereof, to a racemic mixture or its corresponding enantiomer and/or optical isomer and/or stereoisomer thereof. The compounds may be used for the treatment of Alzheimer's disease, cerebral amyloid angiopathy, hereditary cerebral hemorrhage with amyloidosis, Dutch-type (HCHWA-D), multi-infarct dementia, dementia pugilistica or Down syndrome.