2020-08-14から1日間の記事一覧
とあるweb入力formのseleniumによる自動テストを作成する際に役立つかと思い。 次の通りかと思います。 #!/usr/local/bin/python # -*- coding: utf-8 -*- import random def main(): make_random_str(30,["number","kanji","kishuizon"]) def make_random_s…
#!/usr/local/bin/python # -*- coding: utf-8 -*- def main(): str_org = "あいうえお" print(str_org) bytes = str_org.encode("unicode-escape") print(bytes) str_new = bytes.decode("unicode-escape") print(str_new) if __name__ == "__main__": main…