我的文字是: 我想要以下列表: 答案 0 :(得分:0) 或再次将其设为字符串'3. COMMENCEMENT; TERM OF LEASE; AND OPTION TO RENEW\nThe initial term of this Lease shall be for a period of Five (5) years commencing on'
[
'3. COMMENCEMENT; TERM OF LEASE; AND OPTION TO RENEW',
'The initial term of this Lease shall be for a period of Five (5) years commencing on'
]
1 个答案:
>>> initial_statement = "3. COMMENCEMENT; TERM OF LEASE; AND OPTION TO RENEW\nThe initial term of this Lease shall be for a period of Five (5) years commencing on"
>>> temp_list = initial_statement.split("\n")
>>> print(temp_list)
['3. COMMENCEMENT; TERM OF LEASE; AND OPTION TO RENEW', 'The initial term of this Lease shall be for a period of Five (5) years commencing on.']
>>> final_result = ""
>>> for i in temp_list:
... final_result += i
...
>>> print(final_result)
3. COMMENCEMENT; TERM OF LEASE; AND OPTION TO RENEWThe initial term of this Lease shall be for a period of Five (5) years commencing on.