Use \A and \z here instead of ^ and $