Skip to content

Latest commit

 

History

History
36 lines (23 loc) · 605 Bytes

README.md

File metadata and controls

36 lines (23 loc) · 605 Bytes

Power - Mod Power

https://www.hackerrank.com/challenges/python-power-mod-power

Problem

So far, we have only heard of Python's powers. Now, we will witness them!

Task

You are given three integers: a, b, and m, respectively. Print two lines. The first line should print the result of pow(a,b). The second line should print the result of pow(a,b,m).

Input Format

The first line contains a, the second line contains b, and the third line contains m.

Sample Input 0

3
4
5

Sample Output 0

81
1

My Solution