创建一个名为data.txt的文件,使用循环语句向该文件中写入如下内容: 1: I love Python 2: I love Python …… 10: I love Python
举一反三
- var str = " I love java Java java"; var str1 = str.replace(/java/i,"python"); 则str1的值是(): I love java python java|I love python Java java|I love python Java python|I love python python python
- 字符串 s = “I love Python”,以下程序的输出结果是: s = “I love Python” ls = ssplit() lsreverse() print(ls) A: ‘Python’, ‘love’, ‘I’ B: Python love I C: None D: [‘Python’, ‘love’, ‘I’]
- 字符串 s = “I love Python”,以下程序的输出结果是( )。s = "I love Python" ls = s.split() print(ls) A: ‘I’, ‘love’, ‘Python’ B: I love Python C: None D: D. [‘I’, ‘love’,‘Python’ ]
- 以下字符串合法的是(). A: "abe 'def'ghi" B: "I love"love" Python" C: "I love Python' D: 'I love' Python "
- 以下字符串________是合法的。 A: "abc'def 'ghi" B: 'I love Python" C: "I love "love" Python" D: "I love Python''