I have a vector of Foo

```
vector<Foo> inputs

```

Foo is a struct with some score inside

```
struct Foo {
    ...
    float score
    bool winner
}

```

Now I want to sort inputs by score and only assign winner to the top 3. But I don't want to change the original inputs vector. So I guess I need to create a vector of reference then sort that? Is it legal to create a vector of reference? Is there an elegant way to do so?