How to interrupt an Infinite Loop

前端 未结 12 1849
自闭症患者
自闭症患者 2021-02-02 10:36

Though I know it\'ll be a bit silly to ask, still I want to inquire more about the technical perspective of it.

A simple example of an infinite loop:

pub         


        
12条回答
  •  南方客
    南方客 (楼主)
    2021-02-02 10:43

    You cannot stop this from outside of this class. If you use inheritance you can overwrite your loop, but without abort-flag you won't be able to do so.

提交回复
热议问题