more compact code