Python 2, (削除) 199 (削除ここまで) 196 bytes#bytes
-3 bytes thanks to Kevin Cruijssen
from md5 import*
B=bytearray
h=lambda a,b:sum(bin(i^j).count('1')for i,j in zip(B(a),B(b)))
m=lambda a:new(a).hexdigest()
def f(x):
a=b=m(x);i=1
while 1:
b=m(b);i+=1
if h(x,a)==h(x,b):return i
Python 2, (削除) 199 (削除ここまで) 196 bytes#
-3 bytes thanks to Kevin Cruijssen
from md5 import*
B=bytearray
h=lambda a,b:sum(bin(i^j).count('1')for i,j in zip(B(a),B(b)))
m=lambda a:new(a).hexdigest()
def f(x):
a=b=m(x);i=1
while 1:
b=m(b);i+=1
if h(x,a)==h(x,b):return i
Python 2, (削除) 199 (削除ここまで) 196 bytes
-3 bytes thanks to Kevin Cruijssen
from md5 import*
B=bytearray
h=lambda a,b:sum(bin(i^j).count('1')for i,j in zip(B(a),B(b)))
m=lambda a:new(a).hexdigest()
def f(x):
a=b=m(x);i=1
while 1:
b=m(b);i+=1
if h(x,a)==h(x,b):return i
Python 2, (削除) 199 (削除ここまで) 196 bytes#
-3 bytes thanks to Kevin Cruijssen
from md5 import*
B=bytearray
h=lambda a,b:sum(bin(i^j).count('1')for i,j in zip(B(a),B(b)))
m=lambda a:new(a).hexdigest()
def f(x):
a=b=m(x);i=1
while 1:
b=m(b);i+=1
if h(x,a)==h(x,b):return i
Still looking for a better solution; indentations take a lot of bytes
Python 2, (削除) 199 (削除ここまで) 196 bytes#
-3 bytes thanks to Kevin Cruijssen
from md5 import*
B=bytearray
h=lambda a,b:sum(bin(i^j).count('1')for i,j in zip(B(a),B(b)))
m=lambda a:new(a).hexdigest()
def f(x):
a=b=m(x);i=1
while 1:
b=m(b);i+=1
if h(x,a)==h(x,b):return i
Still looking for a better solution; indentations take a lot of bytes
Python 2, (削除) 199 (削除ここまで) 196 bytes#
-3 bytes thanks to Kevin Cruijssen
from md5 import*
B=bytearray
h=lambda a,b:sum(bin(i^j).count('1')for i,j in zip(B(a),B(b)))
m=lambda a:new(a).hexdigest()
def f(x):
a=b=m(x);i=1
while 1:
b=m(b);i+=1
if h(x,a)==h(x,b):return i
Python 2, 199(削除) 199 (削除ここまで) 196 bytes#
-3 bytes thanks to Kevin Cruijssen
from md5 import*
B=bytearray
h=lambda a,b:sum(bin(i^j).count('1')for i,j in zip(B(a),B(b)))
m=lambda a:new(a).hexdigest()
def f(x):
a=b=m(x);i=1
while 1:
b=m(b);i+=1
if h(x,a)==h(x,b):return(i)
Still looking for a better solution; indentations take a lot of bytes
Python 2, 199 bytes#
from md5 import*
B=bytearray
h=lambda a,b:sum(bin(i^j).count('1')for i,j in zip(B(a),B(b)))
m=lambda a:new(a).hexdigest()
def f(x):
a=b=m(x);i=1
while 1:
b=m(b);i+=1
if h(x,a)==h(x,b):return(i)
Still looking for a better solution; indentations take a lot of bytes
Python 2, (削除) 199 (削除ここまで) 196 bytes#
-3 bytes thanks to Kevin Cruijssen
from md5 import*
B=bytearray
h=lambda a,b:sum(bin(i^j).count('1')for i,j in zip(B(a),B(b)))
m=lambda a:new(a).hexdigest()
def f(x):
a=b=m(x);i=1
while 1:
b=m(b);i+=1
if h(x,a)==h(x,b):returni
Still looking for a better solution; indentations take a lot of bytes