Quantcast
Viewing all articles
Browse latest Browse all 39796

MAXPR .. PLZ HELP

plz help me in solving this question ...

http://www.codechef.com/JUNE14/problems/MAXPR

i need clarification .... !!
for example if the series is 1 2 3
then the AP sequences are
1 2 3
1 2
2 3
1 3
1
2
3
so total 7..
so non AP sequences are zero
am i correct?

and anyone plz explain me how to solve this using dp in simple manner.. i am not understanding the editorial properly ..


Viewing all articles
Browse latest Browse all 39796

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>