转载
原文地址:
s="aasdajoijlsknhv" s_hex="" for i in range(len(s)): s_hex=s_hex+hex(ord(s[i]))[2:]+" " print(s_hex)
输出:61 61 73 64 61 6a 6f 69 6a 6c 73 6b 6e 68 76