By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,704 Members | 1,630 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,704 IT Pros & Developers. It's quick & easy.

Estimating the highest value in a set one element at a time

Motoma
Expert 2.5K+
P: 3,237
Hi folks,

I'm having trouble remembering the name of an algorithm I now am trying to reproduce.

The basics of the problem are as such:
  1. Given a finite set of a known length
  2. Look at the first item in the set.
  3. Choose whether to accept that value, or look at the next one
  4. Optimize for the best result, never being able to revisit prior values

So for instance, given a set of numbers [8,23,5,192,3,56,9,11,34,85,23,50,31,5], you are only able to "see" the first element in the list (8). It then needs to decide if that number is sufficient (let's assume we're optimizing for the max value) or if it should continue the search. If it accepts the value, the algorithm is finished, if it continues, it looks at 23, and makes the same assessment. This continues until a value is accepted or the list is complete, with the goal to have the algorithm score higher than random sampling.

Does anyone have the name for this problem, or better yet a wikipedia page for an algorithm to solve this problem?

Thanks in advance,
Motoma
3 Weeks Ago #1

✓ answered by Banfa

I think you are talking about the Secretary Problem https://en.wikipedia.org/wiki/Secretary_problem

Share this Question
Share on Google+
2 Replies


Banfa
Expert Mod 5K+
P: 8,965
I think you are talking about the Secretary Problem https://en.wikipedia.org/wiki/Secretary_problem
3 Weeks Ago #2

Motoma
Expert 2.5K+
P: 3,237
That's exactly what I was looking for, Banfa, thank you so much!
3 Weeks Ago #3

Post your reply

Sign in to post your reply or Sign up for a free account.