python str與bytes之間的轉換

# bytes object b = b"example" # str object s = "example" # str to bytes bytes(s, encoding = "utf8") # bytes to str str(b, encoding = "utf-8") # an alternative method # str to byt
相關文章
相關標籤/搜索