{"id":5862,"date":"2021-05-13T13:16:16","date_gmt":"2021-05-13T07:46:16","guid":{"rendered":"https:\/\/python-programs.com\/?p=5862"},"modified":"2021-11-22T18:42:43","modified_gmt":"2021-11-22T13:12:43","slug":"python-break-keyword-explained-with-examples","status":"publish","type":"post","link":"https:\/\/python-programs.com\/python-break-keyword-explained-with-examples\/","title":{"rendered":"Python: Break keyword \u2013 Explained with Examples"},"content":{"rendered":"

Break Keyword:<\/strong><\/p>\n

The break statement ends the loop that contains it. Control of the programme is transferred to the statement immediately following the body of the loop.<\/p>\n

If the break statement is within a nested loop (a loop within another loop), it will terminate the innermost loop.<\/p>\n

Break keyword in Python<\/h2>\n

We can use break keyword in loops such as while loop and for loop as given below.<\/p>\n