Question: C++ Please read the question carefully. Make sure to print partial results (intermediate steps) of b,n,m (or more details). Partial results is needed. 1. Prompt
C++
Please read the question carefully. Make sure to print partial results (intermediate steps) of b,n,m (or more details). Partial results is needed.
1. Prompt the user to enter three numbers b, n, and m; where 
, and
. 2. Write a recursive function to find the modular exponentiation bn mod m. 3. The function should print partial results and the final result of bn mod m.
Test Cases (make sure to print the partial results):
b = 28, n = 3, m = 17. Answer: 5 b =3768, n = 5, m = 32. Answer: 0 b = 2, n = 5, m = 3. Answer: 2
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
