Classifying a loop exit correctly

A cooling algorithm initializes T=92 ∘CT=92\ ^\circ\text{C} and k=0k=0. It allows at most three updates, each representing 5.0 min5.0\ \text{min}, using the supplied model


Tnew=20+0.5(T−20),T_{\text{new}}=20+0.5(T-20),


with temperatures expressed in degrees Celsius. While both T>29 ∘CT>29\ ^\circ\text{C} and k<3k<3 hold, it updates TT and then increases kk by one. On leaving the loop, it currently reports SUCCESS if k<3k<3 and LIMIT otherwise.


Which replacement final rule correctly distinguishes success from an unmet target for all permitted initial temperatures under this update model?

Choose an answer

Create a free account to get started

Unlock full course notes by signing up

  • Video lessons taught by top educators
  • Practice questions with guided solutions
  • Written review notes for reference
  • Expert answers anytime from course tutors

More Algorithm Development Questions: