Movatterモバイル変換


[0]ホーム

URL:


Previous PageUp One LevelNext PagePython Reference ManualContentsIndex
Previous:6.9 The raise statementUp:6. Simple statementsNext:6.11 The continue statement

 
6.10 Thebreak statement

 

break_stmt ::= "break"
Download entire grammar as text.

break may only occur syntactically nested in afororwhile loop, but not nested in a function or class definitionwithin that loop. 

It terminates the nearest enclosing loop, skipping the optionalelse clause if the loop has one. 

If afor loop is terminated bybreak, the loop controltarget keeps its current value. 

Whenbreak passes control out of atry statementwith afinally clause, thatfinally clause is executedbefore really leaving the loop. 


Previous PageUp One LevelNext PagePython Reference ManualContentsIndex
Previous:6.9 The raise statementUp:6. Simple statementsNext:6.11 The continue statement
Release 2.2.3, documentation updated on 30 May 2003.
SeeAbout this document... for information on suggesting changes.
[8]ページ先頭

©2009-2026 Movatter.jp