[python](備忘録) 辞書(dict) で要素があるかチェック in を使う dictsample = {'aa' : 0, 'bb' : 1} assert ('aa' in dictsample) == True assert ('bb' in dictsample) == True assert ('cc' in dictsample) == False 123456 dictsample = {'aa' : 0, 'bb' : 1}assert ('aa' in dictsample) == Trueassert ('bb' in dictsample) == Trueassert ('cc' in dictsample) == False