def getdecrype(l): a=29 length="" while(1): if(l[a]=="x"): break else: length+=l[a] a+=1 hexnum="" for i in length: hexnum+=l[int(i)] page=int(hexnum,16) return page print(getdecrype("263892b88f81fce313248e0a25bfa5x79071552b")) import hashlib hash = hashlib.md5() hash.update("haha".encode('utf-8')) print(hash.hexdigest())