裏 RjpWiki

Julia ときどき R, Python によるコンピュータプログラム,コンピュータ・サイエンス,統計学

今更ながら思う,あほか,と(Python)

2020年12月07日 | Python

>>> x = [1,2,3,4,5]
>>> y = [3,2,1,5,4]


>>> x*y
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: can't multiply sequence by non-int of type 'list'

>>> x+y
[1, 2, 3, 4, 5, 3, 2, 1, 5, 4]

>>> x-y
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: unsupported operand type(s) for -: 'list' and 'list'

なんの意味があるのやら

コメント    この記事についてブログを書く
  • X
  • Facebookでシェアする
  • はてなブックマークに追加する
  • LINEでシェアする
« また,Hydrogen が動かなくな... | トップ | みんな大好き,R と Python ... »
最新の画像もっと見る

コメントを投稿

Python」カテゴリの最新記事