How to build this query to update all items at once?

Hey guys, I have a schema that has two fields: score & rank.
By default, I insert the documents only with the score, so rank is null.

After all items inserted, I pick 200 by 200 items to update the rank based on the score, but I dont know how I can update all the 200 items at once.

I mean, i will pick the 200 items from the database sorted by the score, so I will know whats the top 1, top 2… But how can I build a query to update all the items at once providing the rank field to each one?

First please followup on