2012-05-13から1日間の記事一覧

pythonで日本語(utf-8)文字列のfind

# -*- coding: utf-8 -*- doc = UTF8の日本語 word = UTF8の日本語if doc.find(word.decode("utf-8")) > -1 : print "hit!"