added all(a) to template