C # in the cycle interrupt --break, continue, return, goto

break: immediately terminate the entire cycle, and the cycle continues the subsequent code.

continue: The cycle immediately jump (continue following code is not executed, the determination condition continues to cycle for the next cycle) <i.e., terminate the current cycle is not the entire cycle>.

return: out of the entire cycle, and the end of the run method of this function, the residual code is not executed.

goto: Jump to the function or method to be executed statement.

Guess you like

Origin blog.csdn.net/peng_1993/article/details/82179225