單項(xiàng)選擇題在Python中,哪個(gè)函數(shù)用于測量字符串長度?()

A.str.size()
B.length(str)
C.len(str)
D.str.length()


您可能感興趣的試卷

你可能感興趣的試題

1.單項(xiàng)選擇題在Python中,哪個(gè)模塊用于科學(xué)計(jì)算?()

A.scipy
B.numpy
C.math
D.所有以上的選項(xiàng)

2.單項(xiàng)選擇題在Python中,如何將字符串轉(zhuǎn)換成日期對象?()

A.datetime.strptime()
B.datetime.parse()
C.date.fromString()
D.parse(date)

3.單項(xiàng)選擇題在Python中,如何創(chuàng)建一個(gè)裝飾器?()

A.def decorator(func)
B.@decorator
C.with decorator
D.A和B都對

4.單項(xiàng)選擇題在Python中,如何獲取一個(gè)模塊的所有函數(shù)和變量?()

A.dir(module)
B.module.__all__
C.module.__dict__
D.module.list()

5.單項(xiàng)選擇題在Python中,如何創(chuàng)建一個(gè)匿名函數(shù)?()

A.lambda
B.anonymous
C.func
D.none