The quest for minimizing different variable

Revision en1, by fierce_adversary, 2024-08-19 12:30:04

Hello everyone,Today, I was working on the CSES Stick Lengths problem, where the solution involves using the median as the optimal value for each element. This got me thinking: what if instead of the median, I used one of the following three values? Which type of deviation or cost would be minimized?

  1. Ceiling value of the mean
  2. Floor value of the mean
  3. Rounded value of the mean

I initially asked ChatGPT about it, but the explanation left me a bit confused. I’m curious to hear your insights on this. Thanks in advance!

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en1 English fierce_adversary 2024-08-19 12:30:04 666 Initial revision (published)