my code is giving error for the test case used in video…i am not able to find the error!
Edmand Karp Code Doubt
please reply///////////////…!
please reply///////////////…!
please reply///////////////…!
please reply///////////////…!
Hello @archa_1712,
Your code is an exact copy of the code in the video.
But, you are still getting a different output.
The only reason for this is the difference in compiler.
In the video, the compiler is initializing the capacity with 0.
But, your case it is not happening.
So, i explicitly coded the initialization.
Corrected code:
Hope, this would help.
Give a like if you are satisfied.