Rhezo and Big Powers

Rhezo likes numbers of the form A^B . But computing A^B , for any 2 numbers Aand B is a hard task for him. He would like you to help him out in this.
        
       Input:-4  3
       Input Description: First line of input contains a single integer A. Second line contains the integer B. 
       Output: 64
       Output Description: Help Rhezo find A^B . As this number can be large, print it modulo 10^9+7 . 
       Constraints: 1<= A <=10^9  1<= B<=10^10
       Explanation: null

Loading...