Armed suspect shot by cop in Brooklyn