Modular exponentiation prob

https://online.codingblocks.com/player/27304/content/8100/5076?tab=submissions

I’m not using std. library functions ,its still failing some test cases.

Plz send your code b y saving on ide only.

Plz use long long int values instead of int, and the approach you are following is bit wrong. Plz use modulo operator at every step.

did the changes u suggested. its still not working https://ide.codingblocks.com/s/104012

I have modified your code a little bit, try to submit it now,