first i submitted using vector (i have done this earlier in other problems successfully ) but got runtime error & same code i submitted using structure(everything was same except i stored the value in struct variable instead of vector ) & … got AC . lol !!
[http://www.codechef.com/viewsolution/3160692][1] (using vector)
[http://www.codechef.com/viewsolution/3160968][2] (using structure)
i’d appreciate if anyone willing to answer …
[1]: http://www.codechef.com/viewsolution/3160692
[2]: http://www.codechef.com/viewsolution/3160968