Strange thing happen in binary search?? PLEASE HELP!!

Правка en2, от rover1, 2019-11-03 15:27:46

Recently i was doing this (https://mirror.codeforces.com/contest/448/problem/D) question and got stuck when my solution goes in infinite loop then i see the correct solution and notice the difference and dry run my code, then i realize my code is incorrect. Now i want to know why this happen.. link to correct solution -- https://mirror.codeforces.com/contest/448/submission/7139620 what i have done is instead of writing l = x+1 i have written l=x Please HELP..

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en2 Английский rover1 2019-11-03 15:27:46 1062
en1 Английский rover1 2019-11-03 15:25:42 1477 Initial revision (published)