added pow and modulo functions