How did abar help ancient Egypt?