單項(xiàng)選擇題在Python中,如何停止一個(gè)無限循環(huán)?()

A.break
B.stop
C.exit
D.return


您可能感興趣的試卷

你可能感興趣的試題

1.單項(xiàng)選擇題在Python中,如何捕獲所有異常?()

A.except Exception as e
B.catch all
C.except
D.try catch

2.單項(xiàng)選擇題在Python中,如何向一個(gè)已存在的文件中寫入數(shù)據(jù)?()

A.open(file,’a’)
B.open(file,’w’)
C.open(file,’r+’)
D.A和C都對(duì)

3.單項(xiàng)選擇題在Python中,如何將一個(gè)字符串分割成列表?()

A.str.split(sep)
B.str.divide(sep)
C.split(str,sep)
D.list(str,sep)

4.單項(xiàng)選擇題在Python中,如何判斷一個(gè)列表是否為空?()

A.len(list)==0
B.list.isEmpty()
C.not list
D.A和C都對(duì)

5.單項(xiàng)選擇題在Python中,如何獲取字符串的子串?()

A.str[start:end]
B.str.sub(start,end)
C.str.slice(start,end)
D.str.substring(start,end)