「python入門」append()で要素を追加するサンプル

2018年5月6日

pythonコード:
>>> cftlist = [1,2,0,’test’]

>>> cftlist

[1, 2, 0, 'test’]

>>> cftlist.append(4)

>>> cftlist

[1, 2, 0, 'test’, 4]

>>> cftlist.append('data’)

>>> cftlist

[1, 2, 0, 'test’, 4, 'data’]

>>>

Python

Posted by arkgame