Getting source limit error in this question .
how to reduce source limit in code ?
link : SPOJ.com - Problem LASTDIG
Here is link to my solution : xKpbHN - Online C++ Compiler & Debugging Tool - Ideone.com
Approach : storing last digit of first 4 power of 1 to 20 (Eg 3^1,3^2,3^3,3^4)
in an array and then answering queries.
I just want to know how to remove source limit error??