You are given N integers that are arranged circularly. There are N ways to pick consecutive subsequences of length M (M < N). For any such subsequence we can find the “K”-value of that subsequence. “K”-value for a given subsequence is the Kth smallest number in that subsequence.

Recommended Answers

There is no question.
So I have solved it.

Jump to Post

All 3 Replies

Show us what you have coded so far.

You might want to look at Python's deque object.

There is no question.
So I have solved it.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.19 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.