my code is almost the same as sir, please help me understand why I am getting a TLE https://ide.codingblocks.com/s/288129
the only difference is that I have used vectors instead of arrays but they haven’t been passed in any function so that shouldn’t make a difference?
Got TLE on SPOJ
i changed my code to match sir’s code and it is still giving TLE https://ide.codingblocks.com/s/288138
@Ishitagambhir hey actually it happens sometime ,test cases are changed regularly there so may be some big test case is added to it so ,use vector instead of array as it is dynamic.
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.