syntaxerror:'break' outside loop

刚学习Python,遇到以下问题,请指教下,谢谢啦!谢谢!谢谢!

img

break是用在循环里的,像你这样else啥也不干的要么去掉else,要么break改成pass。

break只能在for和while循环中使用。if中不能使用break