Given this algorithm written in pseudocode:
Algo(n)
Input: A positive integer n
Output: Answer, Algo(n)
If n = 1
Answer = 3
Else
Answer = 3 × Algo(n-1)
End if
What is Algo(4)?
Please provide a detailed answer! thank you!
The above picture is about pseudocode and tracing the given example
Get Answers For Free
Most questions answered within 1 hours.