Skip to content

upper_bound and lower_bound

ref: https://hackmd.io/@sa072686/cp/%2F%40sa072686%2FHk8wnUcWB

  • upper_bound: first i that a[i] > k
  • lower_bound: first i that a[i] >= k