题目内容

选项:ThankyoutrafficlightshalfanhourturnrightroadsignroundaboutExcuseme对话:Dale:1.CouldyoutellmehowtogettothePalaceMuseum?Nancy:YoucantakeBusNp.5.Thedriverwilltellyouwheretogetoff.Dale:Yes,butI'mdrivingmyowncar.Nancy:Oh,thenyoudrivealongthisstreet,2atthethirdcrossroad,keepstraightonuntilyouseearoadsignthatsays"PalaceMuseum",andthenyoufollowthesign.ItwilldirectyoutothePalaceMuseum.Dale:Drivealongthisstreet,turnright,keepstraight,andthenI'llseethe3?Nancy:That'sright.Dale:4!Oh,bytheway,howlongwillittakeformetogettothemuseum?Nancy:About5.Dale:Thanksagain.You'vebeenveryhelpful.

查看答案
更多问题

s = "abcd",下列哪个语句可以将s中的字母全部大写()。

A. s.replace("a", "A")
B. s = s.replace("a", "A")
C. s.lower()
D. s.upper()

表达式 'abcab'.replace('a','yy') 的值为()。

A. yabcab
B. yybcab
C. yyabcab
D. ayybcab

在python中,字符串的定义有哪些方式?

A. 单引号 '
B. 双引号 ''
C. 三引号 '''
D. 反引号 `

下列说法正确的是()。

A. isalpha()方法判断字符串是否只由字母(英文字母+汉字)组成,空字符串返回False
B. isdigit()方法检测字符串是否只由数字组成
C. isalnum()方法判断字符串是否由字母或数字组成,空字符串返回False,中文按字母处理
D. casefold()方法将字符串所有字母转换成小写

答案查题题库